aboutsummaryrefslogtreecommitdiff
path: root/tests/programs/o3_bounds.zc
diff options
context:
space:
mode:
Diffstat (limited to 'tests/programs/o3_bounds.zc')
-rw-r--r--tests/programs/o3_bounds.zc7
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/programs/o3_bounds.zc b/tests/programs/o3_bounds.zc
index fb347c0..eaf92eb 100644
--- a/tests/programs/o3_bounds.zc
+++ b/tests/programs/o3_bounds.zc
@@ -1,2 +1,5 @@
-// an index outside a []T inside o3 code: caught by the inline check
-fn main() { []int a = new([]int, 5); o3 { int i = 7; a[i] = 1; } free(d*a); return 0; }
+namespace;
+include rt;
+
+// an index outside a T[?] inside o3 code: caught by the inline check
+fn main() { int[?] a = rt.new(int[?], 5); o3 { int i = 7; a[i] = 1; } rt.free(d*a); return 0; }