1
0
Fork 0
mirror of https://github.com/ton-blockchain/ton synced 2025-02-14 20:22:19 +00:00
ton/tolk-tester/tests/invalid-catch-1.tolk
tolk-vm 5b44e01455
[Tolk] Allow cell and slice be valid identifiers
They are not keywords anymore.
> var cell = ...;
> var cell: cell = ...;
Motivation: in the future, when structures are implemented, this obviously should be valid:
> struct a { ... }
> var a = ...;
Struct fields will also be allowed to have names int/slice/cell.
2025-01-27 15:30:21 +03:00

12 lines
153 B
Text

fun main() {
try {
} catch(if, arg) {}
return 0;
}
/**
@compilation_should_fail
@stderr expected identifier, got `if`
@stderr catch(if
*/