mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Grammar for unchecked.
This commit is contained in:
parent
527c073bb9
commit
33d8b62d06
@ -368,7 +368,10 @@ numberLiteral: (DecimalNumber | HexNumber) NumberUnit?;
|
|||||||
/**
|
/**
|
||||||
* A curly-braced block of statements. Opens its own scope.
|
* A curly-braced block of statements. Opens its own scope.
|
||||||
*/
|
*/
|
||||||
block: LBrace statement* RBrace;
|
block:
|
||||||
|
LBrace ( statement | uncheckedBlock )* RBrace;
|
||||||
|
|
||||||
|
uncheckedBlock: Unchecked block;
|
||||||
|
|
||||||
statement:
|
statement:
|
||||||
block
|
block
|
||||||
|
@ -7,7 +7,7 @@ ReservedKeywords:
|
|||||||
'after' | 'alias' | 'apply' | 'auto' | 'case' | 'copyof' | 'default' | 'define' | 'final'
|
'after' | 'alias' | 'apply' | 'auto' | 'case' | 'copyof' | 'default' | 'define' | 'final'
|
||||||
| 'implements' | 'in' | 'inline' | 'let' | 'macro' | 'match' | 'mutable' | 'null' | 'of'
|
| 'implements' | 'in' | 'inline' | 'let' | 'macro' | 'match' | 'mutable' | 'null' | 'of'
|
||||||
| 'partial' | 'promise' | 'reference' | 'relocatable' | 'sealed' | 'sizeof' | 'static'
|
| 'partial' | 'promise' | 'reference' | 'relocatable' | 'sealed' | 'sizeof' | 'static'
|
||||||
| 'supports' | 'switch' | 'typedef' | 'typeof' | 'unchecked' | 'var';
|
| 'supports' | 'switch' | 'typedef' | 'typeof' | 'var';
|
||||||
|
|
||||||
Pragma: 'pragma' -> pushMode(PragmaMode);
|
Pragma: 'pragma' -> pushMode(PragmaMode);
|
||||||
Abstract: 'abstract';
|
Abstract: 'abstract';
|
||||||
@ -87,6 +87,7 @@ True: 'true';
|
|||||||
Try: 'try';
|
Try: 'try';
|
||||||
Type: 'type';
|
Type: 'type';
|
||||||
Ufixed: 'ufixed' | ('ufixed' [0-9]+ 'x' [0-9]+);
|
Ufixed: 'ufixed' | ('ufixed' [0-9]+ 'x' [0-9]+);
|
||||||
|
Unchecked: 'unchecked';
|
||||||
/**
|
/**
|
||||||
* Sized unsigned integer types.
|
* Sized unsigned integer types.
|
||||||
* uint is an alias of uint256.
|
* uint is an alias of uint256.
|
||||||
|
Loading…
Reference in New Issue
Block a user