You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: crates/solidity-v2/inputs/language/src/BREAKING_CHANGES.md
+49Lines changed: 49 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,3 +27,52 @@ We should consider adding validation for these at a later stage if needed:
27
27
- They were only enabled after `0.7.0`.
28
28
-`HexLiteral` and `YulHexLiteral` and `DecimalLiteral` and `YulDecimalLiteral`:
29
29
- It was illegal for them to be followed by `IdentifierStart`. Now we will produce two separate tokens rather than rejecting it.
30
+
31
+
## Language Definition Changes
32
+
33
+
The following changes modify the language definition to support the new parser and resolve grammar ambiguities.
34
+
In some cases we also try to simplify the model.
35
+
36
+
### AddressKeyword
37
+
38
+
- Made the `address` keyword reserved in all versions, handling the few cases where it can be used as an identifier separately.
39
+
-`MemberAccessIdentifier` handles the cases where `address` can be used as an `Identifier`, either in an `IdentifierPath` or a `MemberAccessExpression`.
40
+
41
+
### MemberAccessIdentifier
42
+
43
+
New enum added to allow the reserved `address` keyword in member access expressions (from Solidity 0.6.0):
44
+
45
+
- Variants: `Identifier` | `AddressKeyword` (enabled from 0.6.0)
46
+
- Used in `MemberAccessExpression` (previously just `Identifier`) and in `IdentifierPathTailElements` (for identifier path tails)
47
+
48
+
### IdentifierPath
49
+
50
+
Changed from a simple `Separated` list to a structured format to allow the reserved `address` keyword to appear in identifier paths (but not as the head):
-**After**: `Struct` with `head: Identifier` and `tail: Optional<IdentifierPathTail>`, where `IdentifierPathTail` contains a `Period` separator followed by `IdentifierPathTailElements` (a `Separated` list of `MemberAccessIdentifier`).
54
+
55
+
### TupleDeconstructionStatement
56
+
57
+
Major restructuring to resolve ambiguities with tuple expressions and assignment expressions:
58
+
59
+
-**Before**: Single struct with optional `var_keyword`, `open_paren`, `elements: TupleDeconstructionElements`, `close_paren`, `equal`, `expression`, `semicolon`.
60
+
-**After**: Split into typed and untyped (var) variants:
0 commit comments