test: 更新 Demo20

This commit is contained in:
Luke 2025-08-03 00:08:56 +08:00
parent d3a85a24bf
commit 7c242d998f
2 changed files with 16 additions and 4 deletions

View File

@ -1,11 +1,12 @@
module: Main module: Main
import:os import:os
function: main function: main
return_type: double return_type: void
body: body:
declare n: double[] = [10.0] declare arr: int[] = [1, 2, 3]
arr[0] = 5
return n[0] + 1.0 os.print(arr[0])
end body end body
end function end function
end module end module

View File

@ -0,0 +1,11 @@
module: os
import: os
function: print
parameter:
declare i1: int
return_type: void
body:
syscall("PRINT",i1)
end body
end function
end module