aboutsummaryrefslogtreecommitdiff
path: root/crowbar_reference_compiler/ast.py
diff options
context:
space:
mode:
authorMelody Horn <melody@boringcactus.com>2020-11-05 01:27:58 -0700
committerMelody Horn <melody@boringcactus.com>2020-11-05 01:27:58 -0700
commitb6258d36b6534d521e9cdf1307665c38e5ae409d (patch)
tree7e98020964173869f2799533553bcdcd1f64ea1a /crowbar_reference_compiler/ast.py
parent9dfc552c0703c5e14ea472eb5431719b2e0d6400 (diff)
downloadreference-compiler-b6258d36b6534d521e9cdf1307665c38e5ae409d.tar.gz
reference-compiler-b6258d36b6534d521e9cdf1307665c38e5ae409d.zip
compile based on the fancy new AST
Diffstat (limited to 'crowbar_reference_compiler/ast.py')
-rw-r--r--crowbar_reference_compiler/ast.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/crowbar_reference_compiler/ast.py b/crowbar_reference_compiler/ast.py
index 2a6963c..bb5a4e1 100644
--- a/crowbar_reference_compiler/ast.py
+++ b/crowbar_reference_compiler/ast.py
@@ -530,7 +530,8 @@ class ASTBuilder(NodeVisitor):
return ConstantExpression(body.data)
if body.type in ['true', 'false']:
return ConstantExpression(body.type)
- raise NotImplementedError()
+ if body.type == 'string_literal':
+ return ConstantExpression(body.data)
def visit_StructPointerElementSuffix(self, node, visited_children):
separator, element = visited_children