Export all events.

Update tests.

Additional tests

Revert changes to the Natspec
This commit is contained in:
chriseth
2023-05-03 14:08:27 -03:00
committed by Matheus Aguiar
parent 1af6ca772d
commit 1e63615206
139 changed files with 2697 additions and 152 deletions
@@ -2,4 +2,4 @@ JSON AST (compact format):
======= ast_compact_json_no_pretty_json/input.sol =======
{"absolutePath":"ast_compact_json_no_pretty_json/input.sol","exportedSymbols":{"C":[2]},"id":3,"license":"GPL-3.0","nodeType":"SourceUnit","nodes":[{"id":1,"literals":["solidity",">=","0.0"],"nodeType":"PragmaDirective","src":"36:22:0"},{"abstract":false,"baseContracts":[],"canonicalName":"C","contractDependencies":[],"contractKind":"contract","fullyImplemented":true,"id":2,"linearizedBaseContracts":[2],"name":"C","nameLocation":"69:1:0","nodeType":"ContractDefinition","nodes":[],"scope":3,"src":"60:13:0","usedErrors":[]}],"src":"36:38:0"}
{"absolutePath":"ast_compact_json_no_pretty_json/input.sol","exportedSymbols":{"C":[2]},"id":3,"license":"GPL-3.0","nodeType":"SourceUnit","nodes":[{"id":1,"literals":["solidity",">=","0.0"],"nodeType":"PragmaDirective","src":"36:22:0"},{"abstract":false,"baseContracts":[],"canonicalName":"C","contractDependencies":[],"contractKind":"contract","fullyImplemented":true,"id":2,"linearizedBaseContracts":[2],"name":"C","nameLocation":"69:1:0","nodeType":"ContractDefinition","nodes":[],"scope":3,"src":"60:13:0","usedErrors":[],"usedEvents":[]}],"src":"36:38:0"}
@@ -45,7 +45,8 @@ JSON AST (compact format):
"nodes": [],
"scope": 6,
"src": "60:13:0",
"usedErrors": []
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:38:0"
@@ -56,7 +56,8 @@
"nodes": [],
"scope": 6,
"src": "60:13:0",
"usedErrors": []
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:38:0"
+1
View File
@@ -0,0 +1 @@
--abi --pretty-json --json-indent 4
+16
View File
@@ -0,0 +1,16 @@
// SPDX-License-Identifier: GPL-3.0
pragma solidity >=0.0;
library L {
event e1(uint b);
}
function f() {
emit L.e1(5);
}
contract C {
event e1(uint indexed a);
function g() public {
f();
}
}
+59
View File
@@ -0,0 +1,59 @@
======= events_in_abi/input.sol:C =======
Contract JSON ABI
[
{
"anonymous": false,
"inputs":
[
{
"indexed": false,
"internalType": "uint256",
"name": "b",
"type": "uint256"
}
],
"name": "e1",
"type": "event"
},
{
"anonymous": false,
"inputs":
[
{
"indexed": true,
"internalType": "uint256",
"name": "a",
"type": "uint256"
}
],
"name": "e1",
"type": "event"
},
{
"inputs": [],
"name": "g",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
]
======= events_in_abi/input.sol:L =======
Contract JSON ABI
[
{
"anonymous": false,
"inputs":
[
{
"indexed": false,
"internalType": "uint256",
"name": "b",
"type": "uint256"
}
],
"name": "e1",
"type": "event"
}
]
@@ -180,7 +180,8 @@ JSON AST (compact format):
],
"scope": 19,
"src": "62:399:0",
"usedErrors": []
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:426:0"
@@ -90,7 +90,8 @@
"nodes": [],
"scope": 4,
"src": "59:35:0",
"usedErrors": []
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:84:0"
@@ -85,7 +85,8 @@
],
"scope": 7,
"src": "59:42:0",
"usedErrors": []
"usedErrors": [],
"usedEvents": []
}
],
"src": "36:65:0"