aboutsummaryrefslogtreecommitdiff
path: root/tests/sysy_lvX/025_op_priority1.sy
diff options
context:
space:
mode:
Diffstat (limited to 'tests/sysy_lvX/025_op_priority1.sy')
-rw-r--r--tests/sysy_lvX/025_op_priority1.sy9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/sysy_lvX/025_op_priority1.sy b/tests/sysy_lvX/025_op_priority1.sy
new file mode 100644
index 0000000..2d745b2
--- /dev/null
+++ b/tests/sysy_lvX/025_op_priority1.sy
@@ -0,0 +1,9 @@
+//test the priority of add and mul
+int main(){
+ int a, b, c, d;
+ a = 10;
+ b = 4;
+ c = 2;
+ d = 2;
+ return c + a * b - d;
+} \ No newline at end of file