aboutsummaryrefslogtreecommitdiff
path: root/tests/conformance/4-statements/unchecked_stmt_single.zc
diff options
context:
space:
mode:
Diffstat (limited to 'tests/conformance/4-statements/unchecked_stmt_single.zc')
-rw-r--r--tests/conformance/4-statements/unchecked_stmt_single.zc10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/conformance/4-statements/unchecked_stmt_single.zc b/tests/conformance/4-statements/unchecked_stmt_single.zc
new file mode 100644
index 0000000..2bdccb1
--- /dev/null
+++ b/tests/conformance/4-statements/unchecked_stmt_single.zc
@@ -0,0 +1,10 @@
+// expect: 3/
+// spec 4.9: unchecked stmt
+include rt;
+void pn(int x) { rt.put_n(x); rt.put_c(10); }
+fn main() {
+ int a = 1;
+ unchecked a = a + 2;
+ pn(a);
+ return 0;
+}