aboutsummaryrefslogtreecommitdiff
path: root/parser.d
diff options
context:
space:
mode:
Diffstat (limited to 'parser.d')
-rw-r--r--parser.d10
1 files changed, 9 insertions, 1 deletions
diff --git a/parser.d b/parser.d
index 97557ca..68f5093 100644
--- a/parser.d
+++ b/parser.d
@@ -270,6 +270,7 @@ enum ValueType {
NUMBER,
BOOLEAN,
TYPE,
+ SEQ,
OBJ,
ANY,
NIL,
@@ -281,6 +282,7 @@ union As {
string str;
string type;
Obj obj;
+ Seq seq;
}
@@ -313,6 +315,12 @@ Value makeObjValue(Obj obj) {
return val;
}
+Value makeSeqValue(Seq seq) {
+ As as = { seq: seq };
+ Value val = { ValueType.SEQ, as };
+ return val;
+}
+
Value makeTypeValue(string name) {
As as = { type: name };
Value val = { ValueType.TYPE, as };
@@ -464,7 +472,7 @@ class Parser {
if (next == ')') {
break;
}
- func.addToBody(parseForm());
+ func.addToBody(this.parseForm());
}
if (!peekable()) {