aboutsummaryrefslogtreecommitdiff
path: root/tests/icon/accept/step.zc
diff options
context:
space:
mode:
Diffstat (limited to 'tests/icon/accept/step.zc')
-rw-r--r--tests/icon/accept/step.zc12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/icon/accept/step.zc b/tests/icon/accept/step.zc
new file mode 100644
index 0000000..d394e1e
--- /dev/null
+++ b/tests/icon/accept/step.zc
@@ -0,0 +1,12 @@
+include rt;
+include run;
+include icon;
+fn main() {
+ let q = run.tokens("int n = 4; n = n * 3; return n + bias;");
+ let frame = icon.begin(q);
+ icon.set_global(frame, "bias", 2);
+ icon.step(frame); rt.put_n(icon.local(frame, "n")); rt.put_c(' ');
+ icon.step(frame); rt.put_n(icon.local(frame, "n")); rt.put_c(' ');
+ icon.step(frame); rt.put_n(icon.result(frame)); rt.put_c(10);
+ return 0;
+}