forked from sorbet/sorbet
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implement translation for
PM_CONSTANT_PATH_WRITE_NODE
- Loading branch information
Showing
4 changed files
with
72 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
test/prism_regression/assign_to_constant_path.parse-tree.exp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
Begin { | ||
stmts = [ | ||
Assign { | ||
lhs = ConstLhs { | ||
scope = Const { | ||
scope = NULL | ||
name = <C <U ConstantPath>> | ||
} | ||
name = <C <U RegularAssignment>> | ||
} | ||
rhs = Integer { | ||
val = "1" | ||
} | ||
} | ||
Assign { | ||
lhs = ConstLhs { | ||
scope = Const { | ||
scope = Const { | ||
scope = Cbase { | ||
} | ||
name = <C <U FullyQualified>> | ||
} | ||
name = <C <U ConstantPath>> | ||
} | ||
name = <C <U RegularAssignment>> | ||
} | ||
rhs = Integer { | ||
val = "2" | ||
} | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# typed: false | ||
|
||
# Regular assignment | ||
ConstantPath::RegularAssignment = 1 | ||
::FullyQualified::ConstantPath::RegularAssignment = 2 |