--- /dev/null
+new Object! @=> Object !o;
--- /dev/null
+Object !o;
--- /dev/null
+#! [contains] NullPtrException
+Object ! @ o;
--- /dev/null
+new Object @=> Object ! @ o;
--- /dev/null
+fun void test(Object !o) { <<< o >>>; }
+Object !o => test;
--- /dev/null
+new Object @=> Object !o;
--- /dev/null
+#! [contains] can't cast
+new Object $ Object!;
--- /dev/null
+fun void test(Object !o) { <<< o >>>; }
+new Object => test;
--- /dev/null
+#! [contains] can't assign
+null @=> Object !o;
--- /dev/null
+#! [contains] can't cast
+null $ Object!;
--- /dev/null
+#! [contains] NullPtrException
+fun void test(Object !o) { <<< o >>>; }
+null => test;
--- /dev/null
+#! [contains] NullPtrException
+Object @o @=> Object !o;
--- /dev/null
+#! [contains] NullPtrException
+(Object @ o) $ Object!;
--- /dev/null
+#! [contains] can't implicitly cast
+fun void test(Object !o) { <<< o >>>; }
+Object @o => test;
run "$n" "test arguments" "examples/shred.gw:12" "file"
n=$((n+1))
-good="All heap blocks were freed -- no leaks are possible"
N=$(printf "% 4i" "$n")
-valgrind ./gwion -d silent &> "file"
-ok=0
-grep "$good" "file" > /dev/null && ok=1
-if [ $ok ]
-then echo "ok $N test driver"
-else echo "not ok $N test driver"
-fi
-rm "file"
+run "$n" "simple run" "" "file"
# help
n=$((n+1))