aboutsummaryrefslogtreecommitdiff
path: root/tests/sysy_lvX/041_builtin_getint.sy
diff options
context:
space:
mode:
Diffstat (limited to 'tests/sysy_lvX/041_builtin_getint.sy')
-rw-r--r--tests/sysy_lvX/041_builtin_getint.sy16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/sysy_lvX/041_builtin_getint.sy b/tests/sysy_lvX/041_builtin_getint.sy
new file mode 100644
index 0000000..9d80da4
--- /dev/null
+++ b/tests/sysy_lvX/041_builtin_getint.sy
@@ -0,0 +1,16 @@
+int main()
+{
+ int a;
+ a = getint();
+ int b = 5;
+ int c;
+ c = getint();
+ b = c;
+ int d = getint();
+ b = getint();
+
+ a = a + c;
+ getint();
+ b = b + d;
+ return a + b;
+} \ No newline at end of file