-
Notifications
You must be signed in to change notification settings - Fork 982
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
124 additions
and
0 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import "./l2.sol" as L2; | ||
import {MyErr as MyImportError} from "./l3.sol"; | ||
|
||
type fd is uint; | ||
error MyError(); | ||
uint constant qwe = 34; | ||
|
||
struct SS { | ||
uint g; | ||
} | ||
|
||
enum MyEnum { | ||
A, | ||
B | ||
} | ||
|
||
function tpf(MyEnum p) returns(uint) {return 4;} | ||
function tpf(fd p) pure returns(uint) {return 4;} | ||
function tpf(uint e, SS memory g) view returns(uint) {return 4;} | ||
|
||
library MyC { | ||
function callme() public {} | ||
|
||
} |
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 @@ | ||
function l() {} |
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 @@ | ||
error MyErr(); |
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,20 @@ | ||
import "./l1.sol" as R; | ||
|
||
contract Tp { | ||
|
||
function re(R.SS calldata param1, R.MyEnum param2) public { | ||
R.MyEnum a = R.MyEnum.A; | ||
R.SS memory b = R.SS(R.qwe); | ||
R.MyC.callme(); | ||
R.tpf(2, param1); | ||
R.tpf(param2); | ||
R.tpf(R.fd.wrap(4)); | ||
R.L2.l(); | ||
revert R.MyImportError(); | ||
} | ||
|
||
function re2() public { | ||
revert R.MyError(); | ||
} | ||
|
||
} |
Binary file added
BIN
+5.68 KB
tests/e2e/solc_parsing/test_data/compile/aliasing/main.sol-0.8.19-compact.zip
Binary file not shown.
9 changes: 9 additions & 0 deletions
9
tests/e2e/solc_parsing/test_data/expected/aliasing/main.sol-0.8.19-compact.json
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,9 @@ | ||
{ | ||
"MyC": { | ||
"callme()": "digraph{\n0[label=\"Node Type: ENTRY_POINT 0\n\"];\n}\n" | ||
}, | ||
"Tp": { | ||
"re(SS,MyEnum)": "digraph{\n0[label=\"Node Type: ENTRY_POINT 0\n\"];\n0->1;\n1[label=\"Node Type: NEW VARIABLE 1\n\"];\n1->2;\n2[label=\"Node Type: NEW VARIABLE 2\n\"];\n2->3;\n3[label=\"Node Type: EXPRESSION 3\n\"];\n3->4;\n4[label=\"Node Type: EXPRESSION 4\n\"];\n4->5;\n5[label=\"Node Type: EXPRESSION 5\n\"];\n5->6;\n6[label=\"Node Type: EXPRESSION 6\n\"];\n6->7;\n7[label=\"Node Type: EXPRESSION 7\n\"];\n7->8;\n8[label=\"Node Type: EXPRESSION 8\n\"];\n}\n", | ||
"re2()": "digraph{\n0[label=\"Node Type: ENTRY_POINT 0\n\"];\n0->1;\n1[label=\"Node Type: EXPRESSION 1\n\"];\n}\n" | ||
} | ||
} |