summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xpkg.sh21
-rwxr-xr-xpoint.sh5
-rw-r--r--test.toc4
-rw-r--r--types.c2
4 files changed, 5 insertions, 27 deletions
diff --git a/pkg.sh b/pkg.sh
deleted file mode 100755
index 3ac30dd..0000000
--- a/pkg.sh
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-std_things="io arr"
-cd std
-
-VALGRIND="valgrind --track-origins=yes --exit-on-first-error=yes --error-exitcode=1 -q"
-if [ "$1" = "nov" ]; then
- VALGRIND=""
-fi
-if [ "$CC" = "" ]; then
- CC=gcc
-fi
-
-for thing in $std_things; do
- echo "compiling $thing"
- $VALGRIND ../toc $thing.toc -o $thing.c || exit 1
-done
-cd ..
-echo "compiling test.toc"
-$VALGRIND ./toc test.toc || exit 1
-$CC out.c std/*.c -Wno-builtin-declaration-mismatch || exit 1
-./a.out
diff --git a/point.sh b/point.sh
deleted file mode 100755
index 8156f68..0000000
--- a/point.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-valgrind -q ./toc point.toc -o point.c || exit 1
-valgrind -q ./toc test.toc || exit 1
-gcc point.c out.c -o a.out -O0 -g || exit 1
-./a.out || exit 1
diff --git a/test.toc b/test.toc
index d8916ac..f511440 100644
--- a/test.toc
+++ b/test.toc
@@ -1,6 +1,10 @@
foo ::= nms {
bar ::= 12;
};
+yep :: Namespace = nms {
+bar ::= 12;
+};
+
main ::= fn() {
}; \ No newline at end of file
diff --git a/types.c b/types.c
index 517c1b7..bbed29c 100644
--- a/types.c
+++ b/types.c
@@ -165,7 +165,7 @@ static bool expr_must_lval(Expression *e) {
}
-/* does this type have a Type or a Package in it? (e.g. [5]Type, &&Type) */
+/* does this type have a Type or a Namespace in it? (e.g. [5]Type, &&Namespace) */
static bool type_is_compileonly(Type *t) {
assert(t->flags & TYPE_IS_RESOLVED);
switch (t->kind) {