refactor: 重构死循环测试用例

- 将 initializer 改为 init
- 将 condition 改为 cond
- 将 update 改为 step
This commit is contained in:
Luke 2025-07-14 23:45:01 +08:00
parent c1d0e03b6c
commit e18d7426bc
4 changed files with 12 additions and 12 deletions

View File

@ -15,11 +15,11 @@ module: Math
body:
declare num1:int = 1
loop:
initializer:
init:
declare counter:int = 1
condition:
cond:
counter <= n
update:
step:
counter = counter + 1
body:
num1 = num1 * counter

View File

@ -3,11 +3,11 @@ function: main
return_type: int
body:
loop:
initializer:
init:
declare i:int = 0
condition:
cond:
1 == 1
update:
step:
i = i + 1
body:

View File

@ -5,11 +5,11 @@ module: Main
body:
declare b1: boolean = true
loop:
initializer:
init:
declare i:int = 0
condition:
cond:
b1
update:
step:
i = i + 1
body:

View File

@ -15,11 +15,11 @@ module: Math
body:
declare num1:int = 1
loop:
initializer:
init:
declare counter:int = 1
condition:
cond:
counter <= n
update:
step:
counter = counter + 1
body:
num1 = num1 * counter