mirror of
https://github.com/Brandon-Rozek/matmod.git
synced 2024-11-22 22:06:29 -05:00
Updated hack to adapt for custom connective behavior
This commit is contained in:
parent
646202cb50
commit
312e1aeda5
1 changed files with 6 additions and 3 deletions
|
@ -229,10 +229,13 @@ def parse_size(infile: SourceFile, first_run: bool) -> Optional[int]:
|
||||||
"""
|
"""
|
||||||
Parse the line representing the matrix size.
|
Parse the line representing the matrix size.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
size = int(next(infile))
|
size = int(next(infile))
|
||||||
# HACK: The first size line may be -1 due to a bug. Skip it
|
# HACK: When necessitation and custom connectives are enabled
|
||||||
if size == -1 and first_run:
|
# MaGIC may produce -1s at the beginning of the file
|
||||||
size = int(next(infile))
|
if first_run:
|
||||||
|
while size == -1:
|
||||||
|
size = int(next(infile))
|
||||||
|
|
||||||
if size == -1:
|
if size == -1:
|
||||||
return None
|
return None
|
||||||
|
|
Loading…
Reference in a new issue