Implement nearest-loop transfers and reachable binding analysis
This commit is contained in:
1 parent
095eef1370
commit
69c5dc8d20
40 files changed
+953
-110
No files matched your search
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.break_outside_loop"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
`子函数()`
|
||||
|
||||
`end`
|
||||
|
||||
## @exec 子函数
|
||||
|
||||
`break`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.syntax"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
`break 2`
|
||||
|
||||
`end`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.break_outside_loop"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
## @exec main
|
||||
|
||||
`if true`
|
||||
|
||||
`break`
|
||||
|
||||
`end`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"symbol.uninitialized"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
## @exec main
|
||||
|
||||
`params(标志: Bool)`
|
||||
|
||||
`while true`
|
||||
|
||||
`if 标志`
|
||||
|
||||
`break`
|
||||
|
||||
`end`
|
||||
|
||||
`结果 = 1`
|
||||
|
||||
`break`
|
||||
|
||||
`end`
|
||||
|
||||
`return 结果`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.syntax"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
`continue outer`
|
||||
|
||||
`end`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.continue_outside_loop"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
## @exec main
|
||||
|
||||
`continue`
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.syntax"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
`break 未知`
|
||||
|
||||
`end`
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.continue_outside_loop",
|
||||
"sem.unclosed_control",
|
||||
"sem.unmatched_end"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
### 子段
|
||||
|
||||
`continue`
|
||||
|
||||
`end`
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"codes": [
|
||||
"sem.unclosed_control",
|
||||
"sem.unmatched_end"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
## @exec main
|
||||
|
||||
`while true`
|
||||
|
||||
### @knowledge Loop notes
|
||||
|
||||
`break` `end`
|
||||
|
||||
### @exec Next
|
||||
|
||||
`end`
|
||||
Reference in new issue
Block a user