mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
[FunC] Reserve '!' for the future, identifiers can't start with it
This commit is contained in:
parent
79721d230e
commit
e2467b8ba4
6 changed files with 48 additions and 7 deletions
15
crypto/func/auto-tests/tests/invalid-ident-1.fc
Normal file
15
crypto/func/auto-tests/tests/invalid-ident-1.fc
Normal file
|
@ -0,0 +1,15 @@
|
|||
;; this is allowed, lexer doesn't stop on it
|
||||
int get_false!() { return false; }
|
||||
|
||||
_ main() {
|
||||
var x = false;
|
||||
if (!x) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
{-
|
||||
@compilation_should_fail
|
||||
@stderr '!' is reserved for the future
|
||||
-}
|
Loading…
Add table
Add a link
Reference in a new issue