mirror of
https://github.com/michaelcmartin/Ophis.git
synced 2025-01-02 14:29:35 +00:00
Merge pull request #14 from catseye/fix-templabelcount
Declare templabelcount as a global in atom().
This commit is contained in:
commit
1c7174e696
@ -16,6 +16,7 @@ import os.path
|
||||
|
||||
|
||||
loadedfiles = {}
|
||||
templabelcount = 0
|
||||
|
||||
|
||||
class Lexeme(object):
|
||||
@ -205,6 +206,7 @@ def parse_expr(line):
|
||||
|
||||
def atom():
|
||||
"Parses lowest-priority expression components."
|
||||
global templabelcount
|
||||
next = line.lookahead(0).type
|
||||
if next == "NUM":
|
||||
return IR.ConstantExpr(line.expect("NUM").value)
|
||||
|
Loading…
Reference in New Issue
Block a user