mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Export all events.
Update tests. Additional tests Revert changes to the Natspec
This commit is contained in:
parent
d30ec3548f
commit
c95891b6ed
10
Changelog.md
10
Changelog.md
@ -9,10 +9,18 @@ Compiler Features:
|
||||
Bugfixes:
|
||||
|
||||
|
||||
Important Bugfixes:
|
||||
* ABI: Include events in the ABI that are emitted by a contract but defined outside of it.
|
||||
|
||||
|
||||
AST Changes:
|
||||
* Add field ``emittedEvents`` to ``ContractDefinition`` which contains the AST IDs of all inherited and emitted events.
|
||||
|
||||
|
||||
### 0.8.19 (2023-02-22)
|
||||
|
||||
Language Features:
|
||||
* Allow defining custom operators for user-defined value types via ``using {f as +} for T global`` syntax.
|
||||
* Allow defining custom operators for user-defined value types via ``using {f as +} for T global`` syntax.
|
||||
|
||||
|
||||
Compiler Features:
|
||||
|
@ -243,6 +243,21 @@ vector<EventDefinition const*> const ContractDefinition::usedInterfaceEvents() c
|
||||
);
|
||||
}
|
||||
|
||||
vector<EventDefinition const*> ContractDefinition::interfaceEvents(bool _requireCallGraph) const
|
||||
{
|
||||
set<EventDefinition const*, CompareByID> result;
|
||||
for (ContractDefinition const* contract: annotation().linearizedBaseContracts)
|
||||
result += contract->events();
|
||||
solAssert(annotation().creationCallGraph.set() == annotation().deployedCallGraph.set());
|
||||
if (_requireCallGraph)
|
||||
solAssert(annotation().creationCallGraph.set());
|
||||
if (annotation().creationCallGraph.set())
|
||||
result += usedInterfaceEvents();
|
||||
// We could filter out all events that do not have an external interface
|
||||
// if _requireCallGraph is false.
|
||||
return util::convertContainer<vector<EventDefinition const*>>(std::move(result));
|
||||
}
|
||||
|
||||
vector<ErrorDefinition const*> ContractDefinition::interfaceErrors(bool _requireCallGraph) const
|
||||
{
|
||||
set<ErrorDefinition const*, CompareByID> result;
|
||||
|
@ -522,6 +522,10 @@ public:
|
||||
std::vector<EventDefinition const*> events() const { return filteredNodes<EventDefinition>(m_subNodes); }
|
||||
std::vector<EventDefinition const*> const& definedInterfaceEvents() const;
|
||||
std::vector<EventDefinition const*> const usedInterfaceEvents() const;
|
||||
/// @return all events defined in this contract and its base contracts and all events
|
||||
/// that are emitted during the execution of the contract.
|
||||
/// @param _requireCallGraph if false, do not fail if the call graph has not been computed yet.
|
||||
std::vector<EventDefinition const*> interfaceEvents(bool _requireCallGraph = true) const;
|
||||
/// @returns all errors defined in this contract or any base contract
|
||||
/// and all errors referenced during execution.
|
||||
/// @param _requireCallGraph if false, do not fail if the call graph has not been computed yet.
|
||||
|
@ -286,6 +286,8 @@ bool ASTJsonExporter::visit(ContractDefinition const& _node)
|
||||
make_pair("abstract", _node.abstract()),
|
||||
make_pair("baseContracts", toJson(_node.baseContracts())),
|
||||
make_pair("contractDependencies", getContainerIds(_node.annotation().contractDependencies | ranges::views::keys)),
|
||||
// Do not require call graph because the AST is also created for incorrect sources.
|
||||
make_pair("emittedEvents", getContainerIds(_node.interfaceEvents(false))),
|
||||
make_pair("usedErrors", getContainerIds(_node.interfaceErrors(false))),
|
||||
make_pair("nodes", toJson(_node.subNodes())),
|
||||
make_pair("scope", idOrNull(_node.scope()))
|
||||
|
@ -101,7 +101,7 @@ Json::Value ABI::generate(ContractDefinition const& _contractDef)
|
||||
method["stateMutability"] = stateMutabilityToString(externalFunctionType->stateMutability());
|
||||
abi.emplace(std::move(method));
|
||||
}
|
||||
for (auto const& it: _contractDef.definedInterfaceEvents())
|
||||
for (auto const& it: _contractDef.interfaceEvents())
|
||||
{
|
||||
Json::Value event{Json::objectValue};
|
||||
event["type"] = "event";
|
||||
|
@ -82,7 +82,11 @@ Json::Value Natspec::userDocumentation(ContractDefinition const& _contractDef)
|
||||
{
|
||||
string value = extractDoc(event->annotation().docTags, "notice");
|
||||
if (!value.empty())
|
||||
doc["events"][event->functionType(true)->externalSignature()]["notice"] = value;
|
||||
{
|
||||
Json::Value eventDoc{Json::objectValue};
|
||||
eventDoc["notice"] = value;
|
||||
doc["events"][event->functionType(true)->externalSignature()].append(std::move(eventDoc));
|
||||
}
|
||||
}
|
||||
|
||||
for (auto const& error: _contractDef.interfaceErrors())
|
||||
|
@ -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","emittedEvents":[],"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"}
|
||||
|
@ -33,6 +33,7 @@ JSON AST (compact format):
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -44,6 +44,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
1
test/cmdlineTests/events_in_abi/args
Normal file
1
test/cmdlineTests/events_in_abi/args
Normal file
@ -0,0 +1 @@
|
||||
--abi --pretty-json --json-indent 4
|
16
test/cmdlineTests/events_in_abi/input.sol
Normal file
16
test/cmdlineTests/events_in_abi/input.sol
Normal 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
test/cmdlineTests/events_in_abi/output
Normal file
59
test/cmdlineTests/events_in_abi/output
Normal 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"
|
||||
}
|
||||
]
|
@ -34,6 +34,7 @@ JSON AST (compact format):
|
||||
"canonicalName": "Error1",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 18,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -78,6 +78,7 @@
|
||||
"canonicalName": "Errort6",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 3,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -35,6 +35,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -0,0 +1,42 @@
|
||||
contract C {
|
||||
event e();
|
||||
function f() public {
|
||||
emit e();
|
||||
}
|
||||
}
|
||||
|
||||
contract D {
|
||||
C c;
|
||||
constructor() {
|
||||
c = new C();
|
||||
c.f();
|
||||
}
|
||||
}
|
||||
|
||||
// ----
|
||||
// :C
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "name": "f",
|
||||
// "outputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "function"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :D
|
||||
// [
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "constructor"
|
||||
// }
|
||||
// ]
|
62
test/libsolidity/ABIJson/event_inheritance.sol
Normal file
62
test/libsolidity/ABIJson/event_inheritance.sol
Normal file
@ -0,0 +1,62 @@
|
||||
interface B {
|
||||
event EB();
|
||||
}
|
||||
|
||||
contract C is B {
|
||||
event EC();
|
||||
}
|
||||
|
||||
contract D is C {
|
||||
event ED();
|
||||
}
|
||||
|
||||
// ----
|
||||
// :B
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "EB",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :C
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "EB",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "EC",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :D
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "EB",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "EC",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "ED",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
88
test/libsolidity/ABIJson/events_indirect.sol
Normal file
88
test/libsolidity/ABIJson/events_indirect.sol
Normal file
@ -0,0 +1,88 @@
|
||||
library L {
|
||||
event e1(uint b);
|
||||
event e2();
|
||||
event e2(uint a);
|
||||
event e3() anonymous;
|
||||
}
|
||||
contract test {
|
||||
function f() public {
|
||||
emit L.e1(1);
|
||||
emit L.e3();
|
||||
}
|
||||
}
|
||||
// ----
|
||||
// :L
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs":
|
||||
// [
|
||||
// {
|
||||
// "indexed": false,
|
||||
// "internalType": "uint256",
|
||||
// "name": "b",
|
||||
// "type": "uint256"
|
||||
// }
|
||||
// ],
|
||||
// "name": "e1",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e2",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs":
|
||||
// [
|
||||
// {
|
||||
// "indexed": false,
|
||||
// "internalType": "uint256",
|
||||
// "name": "a",
|
||||
// "type": "uint256"
|
||||
// }
|
||||
// ],
|
||||
// "name": "e2",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": true,
|
||||
// "inputs": [],
|
||||
// "name": "e3",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :test
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs":
|
||||
// [
|
||||
// {
|
||||
// "indexed": false,
|
||||
// "internalType": "uint256",
|
||||
// "name": "b",
|
||||
// "type": "uint256"
|
||||
// }
|
||||
// ],
|
||||
// "name": "e1",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": true,
|
||||
// "inputs": [],
|
||||
// "name": "e3",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "name": "f",
|
||||
// "outputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "function"
|
||||
// }
|
||||
// ]
|
45
test/libsolidity/ABIJson/events_repetitions.sol
Normal file
45
test/libsolidity/ABIJson/events_repetitions.sol
Normal file
@ -0,0 +1,45 @@
|
||||
library L {
|
||||
event e();
|
||||
}
|
||||
contract C {
|
||||
constructor() {
|
||||
emit L.e();
|
||||
}
|
||||
function f() public {
|
||||
emit L.e();
|
||||
}
|
||||
}
|
||||
|
||||
// ----
|
||||
// :C
|
||||
// [
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "constructor"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "name": "f",
|
||||
// "outputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "function"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :L
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
61
test/libsolidity/ABIJson/same_event_defined_twice.sol
Normal file
61
test/libsolidity/ABIJson/same_event_defined_twice.sol
Normal file
@ -0,0 +1,61 @@
|
||||
library L1 { event e(); }
|
||||
library L2 { event e(); }
|
||||
contract C {
|
||||
constructor() {
|
||||
emit L1.e();
|
||||
}
|
||||
function f() public {
|
||||
emit L2.e();
|
||||
}
|
||||
}
|
||||
|
||||
// ----
|
||||
// :C
|
||||
// [
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "constructor"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// },
|
||||
// {
|
||||
// "inputs": [],
|
||||
// "name": "f",
|
||||
// "outputs": [],
|
||||
// "stateMutability": "nonpayable",
|
||||
// "type": "function"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :L1
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
||||
//
|
||||
//
|
||||
// :L2
|
||||
// [
|
||||
// {
|
||||
// "anonymous": false,
|
||||
// "inputs": [],
|
||||
// "name": "e",
|
||||
// "type": "event"
|
||||
// }
|
||||
// ]
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 5,
|
||||
"name": "C",
|
||||
"nameLocation": "18:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 39,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 39,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 4,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 4,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 8,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 8,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 12,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 12,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 6,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 6,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 9,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 9,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -21,6 +21,7 @@
|
||||
"canonicalName": "A",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 7,
|
||||
"linearizedBaseContracts":
|
||||
@ -129,6 +130,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 17,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 7,
|
||||
"name": "A",
|
||||
"nameLocation": "9:1:1",
|
||||
@ -98,6 +99,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 17,
|
||||
"name": "C",
|
||||
"nameLocation": "45:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 5,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -33,6 +33,7 @@
|
||||
"canonicalName": "A",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 1,
|
||||
"linearizedBaseContracts":
|
||||
@ -72,6 +73,7 @@
|
||||
"canonicalName": "B",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 4,
|
||||
"linearizedBaseContracts":
|
||||
@ -112,6 +114,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 7,
|
||||
"linearizedBaseContracts":
|
||||
@ -153,6 +156,7 @@
|
||||
"canonicalName": "D",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 10,
|
||||
"linearizedBaseContracts":
|
||||
@ -195,6 +199,7 @@
|
||||
"canonicalName": "E",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 13,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 1,
|
||||
"name": "A",
|
||||
"nameLocation": "9:1:1",
|
||||
@ -40,6 +41,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 4,
|
||||
"name": "B",
|
||||
"nameLocation": "24:1:1",
|
||||
@ -71,6 +73,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 7,
|
||||
"name": "C",
|
||||
"nameLocation": "44:1:1",
|
||||
@ -102,6 +105,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 10,
|
||||
"name": "D",
|
||||
"nameLocation": "64:1:1",
|
||||
@ -133,6 +137,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 13,
|
||||
"name": "E",
|
||||
"nameLocation": "84:1:1",
|
||||
|
@ -25,6 +25,7 @@
|
||||
"src": "0:27:1",
|
||||
"text": "This contract is empty"
|
||||
},
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 2,
|
||||
"linearizedBaseContracts":
|
||||
@ -68,6 +69,7 @@
|
||||
"src": "0:61:2",
|
||||
"text": "This contract is empty\nand has a line-breaking comment."
|
||||
},
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
@ -104,6 +106,10 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
12
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 23,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 41,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 41,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 27,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 27,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"src": "0:27:1",
|
||||
"text": "This contract is empty"
|
||||
},
|
||||
"emittedEvents": [],
|
||||
"id": 2,
|
||||
"name": "C",
|
||||
"nameLocation": "37:1:1",
|
||||
@ -46,6 +47,7 @@
|
||||
"src": "0:61:2",
|
||||
"text": "This contract is empty\nand has a line-breaking comment."
|
||||
},
|
||||
"emittedEvents": [],
|
||||
"id": 5,
|
||||
"name": "C",
|
||||
"nameLocation": "71:1:2",
|
||||
@ -68,6 +70,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 23,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:3",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 28,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 28,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 4,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 4,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
398
test/libsolidity/ASTJSON/event_aggregated_contract.json
Normal file
398
test/libsolidity/ASTJSON/event_aggregated_contract.json
Normal file
@ -0,0 +1,398 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"exportedSymbols":
|
||||
{
|
||||
"C":
|
||||
[
|
||||
10
|
||||
],
|
||||
"D":
|
||||
[
|
||||
30
|
||||
]
|
||||
},
|
||||
"id": 31,
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
2
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 10,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
10
|
||||
],
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "ffae15ba29768297c9b951e2e14bc33dc84599d1572acc234266fc70392babc8",
|
||||
"id": 2,
|
||||
"name": "e",
|
||||
"nameLocation": "23:1:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "24:2:1"
|
||||
},
|
||||
"src": "17:10:1"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 8,
|
||||
"nodeType": "Block",
|
||||
"src": "52:25:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"eventCall":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"id": 5,
|
||||
"name": "e",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 2,
|
||||
"src": "67:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_event_nonpayable$__$returns$__$",
|
||||
"typeString": "function ()"
|
||||
}
|
||||
},
|
||||
"id": 6,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "67:3:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_tuple$__$",
|
||||
"typeString": "tuple()"
|
||||
}
|
||||
},
|
||||
"id": 7,
|
||||
"nodeType": "EmitStatement",
|
||||
"src": "62:8:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"functionSelector": "26121ff0",
|
||||
"id": 9,
|
||||
"implemented": true,
|
||||
"kind": "function",
|
||||
"modifiers": [],
|
||||
"name": "f",
|
||||
"nameLocation": "41:1:1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 3,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "42:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 4,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "52:0:1"
|
||||
},
|
||||
"scope": 10,
|
||||
"src": "32:45:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "public"
|
||||
}
|
||||
],
|
||||
"scope": 31,
|
||||
"src": "0:79:1",
|
||||
"usedErrors": []
|
||||
},
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"canonicalName": "D",
|
||||
"contractDependencies":
|
||||
[
|
||||
10
|
||||
],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 30,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
30
|
||||
],
|
||||
"name": "D",
|
||||
"nameLocation": "89:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"constant": false,
|
||||
"id": 13,
|
||||
"mutability": "mutable",
|
||||
"name": "c",
|
||||
"nameLocation": "99:1:1",
|
||||
"nodeType": "VariableDeclaration",
|
||||
"scope": 30,
|
||||
"src": "97:3:1",
|
||||
"stateVariable": true,
|
||||
"storageLocation": "default",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
},
|
||||
"typeName":
|
||||
{
|
||||
"id": 12,
|
||||
"nodeType": "UserDefinedTypeName",
|
||||
"pathNode":
|
||||
{
|
||||
"id": 11,
|
||||
"name": "C",
|
||||
"nameLocations":
|
||||
[
|
||||
"97:1:1"
|
||||
],
|
||||
"nodeType": "IdentifierPath",
|
||||
"referencedDeclaration": 10,
|
||||
"src": "97:1:1"
|
||||
},
|
||||
"referencedDeclaration": 10,
|
||||
"src": "97:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
},
|
||||
"visibility": "internal"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 28,
|
||||
"nodeType": "Block",
|
||||
"src": "120:43:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"expression":
|
||||
{
|
||||
"id": 21,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"lValueRequested": false,
|
||||
"leftHandSide":
|
||||
{
|
||||
"id": 16,
|
||||
"name": "c",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 13,
|
||||
"src": "130:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
},
|
||||
"nodeType": "Assignment",
|
||||
"operator": "=",
|
||||
"rightHandSide":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"id": 19,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"lValueRequested": false,
|
||||
"nodeType": "NewExpression",
|
||||
"src": "134:5:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_creation_nonpayable$__$returns$_t_contract$_C_$10_$",
|
||||
"typeString": "function () returns (contract C)"
|
||||
},
|
||||
"typeName":
|
||||
{
|
||||
"id": 18,
|
||||
"nodeType": "UserDefinedTypeName",
|
||||
"pathNode":
|
||||
{
|
||||
"id": 17,
|
||||
"name": "C",
|
||||
"nameLocations":
|
||||
[
|
||||
"138:1:1"
|
||||
],
|
||||
"nodeType": "IdentifierPath",
|
||||
"referencedDeclaration": 10,
|
||||
"src": "138:1:1"
|
||||
},
|
||||
"referencedDeclaration": 10,
|
||||
"src": "138:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
}
|
||||
},
|
||||
"id": 20,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "134:7:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
},
|
||||
"src": "130:11:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
},
|
||||
"id": 22,
|
||||
"nodeType": "ExpressionStatement",
|
||||
"src": "130:11:1"
|
||||
},
|
||||
{
|
||||
"expression":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"expression":
|
||||
{
|
||||
"id": 23,
|
||||
"name": "c",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 13,
|
||||
"src": "151:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_contract$_C_$10",
|
||||
"typeString": "contract C"
|
||||
}
|
||||
},
|
||||
"id": 25,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"lValueRequested": false,
|
||||
"memberLocation": "153:1:1",
|
||||
"memberName": "f",
|
||||
"nodeType": "MemberAccess",
|
||||
"referencedDeclaration": 9,
|
||||
"src": "151:3:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_external_nonpayable$__$returns$__$",
|
||||
"typeString": "function () external"
|
||||
}
|
||||
},
|
||||
"id": 26,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "151:5:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_tuple$__$",
|
||||
"typeString": "tuple()"
|
||||
}
|
||||
},
|
||||
"id": 27,
|
||||
"nodeType": "ExpressionStatement",
|
||||
"src": "151:5:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"id": 29,
|
||||
"implemented": true,
|
||||
"kind": "constructor",
|
||||
"modifiers": [],
|
||||
"name": "",
|
||||
"nameLocation": "-1:-1:-1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 14,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "117:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 15,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "120:0:1"
|
||||
},
|
||||
"scope": 30,
|
||||
"src": "106:57:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "public"
|
||||
}
|
||||
],
|
||||
"scope": 31,
|
||||
"src": "80:85:1",
|
||||
"usedErrors": []
|
||||
}
|
||||
],
|
||||
"src": "0:166:1"
|
||||
}
|
15
test/libsolidity/ASTJSON/event_aggregated_contract.sol
Normal file
15
test/libsolidity/ASTJSON/event_aggregated_contract.sol
Normal file
@ -0,0 +1,15 @@
|
||||
contract C {
|
||||
event e();
|
||||
function f() public {
|
||||
emit e();
|
||||
}
|
||||
}
|
||||
contract D {
|
||||
C c;
|
||||
constructor() {
|
||||
c = new C();
|
||||
c.f();
|
||||
}
|
||||
}
|
||||
|
||||
// ----
|
@ -17,6 +17,10 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
2
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 3,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 3,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
194
test/libsolidity/ASTJSON/event_inheritance.json
Normal file
194
test/libsolidity/ASTJSON/event_inheritance.json
Normal file
@ -0,0 +1,194 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"exportedSymbols":
|
||||
{
|
||||
"B":
|
||||
[
|
||||
3
|
||||
],
|
||||
"C":
|
||||
[
|
||||
8
|
||||
],
|
||||
"D":
|
||||
[
|
||||
13
|
||||
]
|
||||
},
|
||||
"id": 14,
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"canonicalName": "B",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "interface",
|
||||
"emittedEvents":
|
||||
[
|
||||
2
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 3,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
3
|
||||
],
|
||||
"name": "B",
|
||||
"nameLocation": "10:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "dbec0351ad6bb0c1f07ea56e236e3e692fde2259f0165fd422f241da339b7e4f",
|
||||
"id": 2,
|
||||
"name": "EB",
|
||||
"nameLocation": "24:2:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "26:2:1"
|
||||
},
|
||||
"src": "18:11:1"
|
||||
}
|
||||
],
|
||||
"scope": 14,
|
||||
"src": "0:31:1",
|
||||
"usedErrors": []
|
||||
},
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts":
|
||||
[
|
||||
{
|
||||
"baseName":
|
||||
{
|
||||
"id": 4,
|
||||
"name": "B",
|
||||
"nameLocations":
|
||||
[
|
||||
"46:1:1"
|
||||
],
|
||||
"nodeType": "IdentifierPath",
|
||||
"referencedDeclaration": 3,
|
||||
"src": "46:1:1"
|
||||
},
|
||||
"id": 5,
|
||||
"nodeType": "InheritanceSpecifier",
|
||||
"src": "46:1:1"
|
||||
}
|
||||
],
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
2,
|
||||
7
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 8,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
8,
|
||||
3
|
||||
],
|
||||
"name": "C",
|
||||
"nameLocation": "41:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "a08b3367d3fa83ea27f8951ffb5d9d160cbfadbd80816b47f677e7699d76f5a0",
|
||||
"id": 7,
|
||||
"name": "EC",
|
||||
"nameLocation": "60:2:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 6,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "62:2:1"
|
||||
},
|
||||
"src": "54:11:1"
|
||||
}
|
||||
],
|
||||
"scope": 14,
|
||||
"src": "32:35:1",
|
||||
"usedErrors": []
|
||||
},
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts":
|
||||
[
|
||||
{
|
||||
"baseName":
|
||||
{
|
||||
"id": 9,
|
||||
"name": "C",
|
||||
"nameLocations":
|
||||
[
|
||||
"82:1:1"
|
||||
],
|
||||
"nodeType": "IdentifierPath",
|
||||
"referencedDeclaration": 8,
|
||||
"src": "82:1:1"
|
||||
},
|
||||
"id": 10,
|
||||
"nodeType": "InheritanceSpecifier",
|
||||
"src": "82:1:1"
|
||||
}
|
||||
],
|
||||
"canonicalName": "D",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
2,
|
||||
7,
|
||||
12
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 13,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
13,
|
||||
8,
|
||||
3
|
||||
],
|
||||
"name": "D",
|
||||
"nameLocation": "77:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "caa54b91a2314ab89b39714b1cd283762e53a2f59cfb997d6770e2824c39db0d",
|
||||
"id": 12,
|
||||
"name": "ED",
|
||||
"nameLocation": "96:2:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 11,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "98:2:1"
|
||||
},
|
||||
"src": "90:11:1"
|
||||
}
|
||||
],
|
||||
"scope": 14,
|
||||
"src": "68:35:1",
|
||||
"usedErrors": []
|
||||
}
|
||||
],
|
||||
"src": "0:104:1"
|
||||
}
|
9
test/libsolidity/ASTJSON/event_inheritance.sol
Normal file
9
test/libsolidity/ASTJSON/event_inheritance.sol
Normal file
@ -0,0 +1,9 @@
|
||||
interface B {
|
||||
event EB();
|
||||
}
|
||||
contract C is B {
|
||||
event EC();
|
||||
}
|
||||
contract D is C {
|
||||
event ED();
|
||||
}
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 7,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -36,6 +36,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "interface",
|
||||
"emittedEvents": [],
|
||||
"id": 29,
|
||||
"name": "I",
|
||||
"nameLocation": "31:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 9,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 9,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 5,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 5,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 5,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 17,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 17,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
319
test/libsolidity/ASTJSON/indirect_event.json
Normal file
319
test/libsolidity/ASTJSON/indirect_event.json
Normal file
@ -0,0 +1,319 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"exportedSymbols":
|
||||
{
|
||||
"C":
|
||||
[
|
||||
25
|
||||
],
|
||||
"L":
|
||||
[
|
||||
10
|
||||
]
|
||||
},
|
||||
"id": 26,
|
||||
"license": "GPL-3.0",
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"canonicalName": "L",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "library",
|
||||
"emittedEvents":
|
||||
[
|
||||
2
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 10,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
10
|
||||
],
|
||||
"name": "L",
|
||||
"nameLocation": "44:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "92bbf6e823a631f3c8e09b1c8df90f378fb56f7fbc9701827e1ff8aad7f6a028",
|
||||
"id": 2,
|
||||
"name": "E",
|
||||
"nameLocation": "58:1:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "59:2:1"
|
||||
},
|
||||
"src": "52:10:1"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 8,
|
||||
"nodeType": "Block",
|
||||
"src": "89:13:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"eventCall":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"id": 5,
|
||||
"name": "E",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 2,
|
||||
"src": "96:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_event_nonpayable$__$returns$__$",
|
||||
"typeString": "function ()"
|
||||
}
|
||||
},
|
||||
"id": 6,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "96:3:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_tuple$__$",
|
||||
"typeString": "tuple()"
|
||||
}
|
||||
},
|
||||
"id": 7,
|
||||
"nodeType": "EmitStatement",
|
||||
"src": "91:8:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"id": 9,
|
||||
"implemented": true,
|
||||
"kind": "function",
|
||||
"modifiers": [],
|
||||
"name": "f",
|
||||
"nameLocation": "76:1:1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 3,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "77:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 4,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "89:0:1"
|
||||
},
|
||||
"scope": 10,
|
||||
"src": "67:35:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "internal"
|
||||
}
|
||||
],
|
||||
"scope": 26,
|
||||
"src": "36:68:1",
|
||||
"usedErrors": []
|
||||
},
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents":
|
||||
[
|
||||
2,
|
||||
12
|
||||
],
|
||||
"fullyImplemented": true,
|
||||
"id": 25,
|
||||
"linearizedBaseContracts":
|
||||
[
|
||||
25
|
||||
],
|
||||
"name": "C",
|
||||
"nameLocation": "114:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"eventSelector": "70a5d861ef9816388422765f41d618eb3abdf490acb37354b539729e37b09f0e",
|
||||
"id": 12,
|
||||
"name": "H",
|
||||
"nameLocation": "128:1:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 11,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "129:2:1"
|
||||
},
|
||||
"src": "122:10:1"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 23,
|
||||
"nodeType": "Block",
|
||||
"src": "157:20:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"expression":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"expression":
|
||||
{
|
||||
"id": 15,
|
||||
"name": "L",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 10,
|
||||
"src": "159:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_type$_t_contract$_L_$10_$",
|
||||
"typeString": "type(library L)"
|
||||
}
|
||||
},
|
||||
"id": 17,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"lValueRequested": false,
|
||||
"memberLocation": "161:1:1",
|
||||
"memberName": "f",
|
||||
"nodeType": "MemberAccess",
|
||||
"referencedDeclaration": 9,
|
||||
"src": "159:3:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_internal_nonpayable$__$returns$__$",
|
||||
"typeString": "function ()"
|
||||
}
|
||||
},
|
||||
"id": 18,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "159:5:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_tuple$__$",
|
||||
"typeString": "tuple()"
|
||||
}
|
||||
},
|
||||
"id": 19,
|
||||
"nodeType": "ExpressionStatement",
|
||||
"src": "159:5:1"
|
||||
},
|
||||
{
|
||||
"eventCall":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"argumentTypes": [],
|
||||
"id": 20,
|
||||
"name": "H",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"referencedDeclaration": 12,
|
||||
"src": "171:1:1",
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_function_event_nonpayable$__$returns$__$",
|
||||
"typeString": "function ()"
|
||||
}
|
||||
},
|
||||
"id": 21,
|
||||
"isConstant": false,
|
||||
"isLValue": false,
|
||||
"isPure": false,
|
||||
"kind": "functionCall",
|
||||
"lValueRequested": false,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "171:3:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions":
|
||||
{
|
||||
"typeIdentifier": "t_tuple$__$",
|
||||
"typeString": "tuple()"
|
||||
}
|
||||
},
|
||||
"id": 22,
|
||||
"nodeType": "EmitStatement",
|
||||
"src": "166:8:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"functionSelector": "e2179b8e",
|
||||
"id": 24,
|
||||
"implemented": true,
|
||||
"kind": "function",
|
||||
"modifiers": [],
|
||||
"name": "g",
|
||||
"nameLocation": "146:1:1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 13,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "147:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 14,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "157:0:1"
|
||||
},
|
||||
"scope": 25,
|
||||
"src": "137:40:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "public"
|
||||
}
|
||||
],
|
||||
"scope": 26,
|
||||
"src": "105:74:1",
|
||||
"usedErrors": []
|
||||
}
|
||||
],
|
||||
"src": "36:144:1"
|
||||
}
|
11
test/libsolidity/ASTJSON/indirect_event.sol
Normal file
11
test/libsolidity/ASTJSON/indirect_event.sol
Normal file
@ -0,0 +1,11 @@
|
||||
// SPDX-License-Identifier: GPL-3.0
|
||||
library L {
|
||||
event E();
|
||||
function f() internal { emit E(); }
|
||||
}
|
||||
contract C {
|
||||
event H();
|
||||
function g() public { L.f(); emit H(); }
|
||||
}
|
||||
|
||||
// ----
|
228
test/libsolidity/ASTJSON/indirect_event_parseOnly.json
Normal file
228
test/libsolidity/ASTJSON/indirect_event_parseOnly.json
Normal file
@ -0,0 +1,228 @@
|
||||
{
|
||||
"absolutePath": "a",
|
||||
"id": 26,
|
||||
"license": "GPL-3.0",
|
||||
"nodeType": "SourceUnit",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "library",
|
||||
"emittedEvents": [],
|
||||
"id": 10,
|
||||
"name": "L",
|
||||
"nameLocation": "44:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"id": 2,
|
||||
"name": "E",
|
||||
"nameLocation": "58:1:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 1,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "59:2:1"
|
||||
},
|
||||
"src": "52:10:1"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 8,
|
||||
"nodeType": "Block",
|
||||
"src": "89:13:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"eventCall":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"id": 5,
|
||||
"name": "E",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"src": "96:1:1",
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 6,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "96:3:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 7,
|
||||
"nodeType": "EmitStatement",
|
||||
"src": "91:8:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"id": 9,
|
||||
"implemented": true,
|
||||
"kind": "function",
|
||||
"modifiers": [],
|
||||
"name": "f",
|
||||
"nameLocation": "76:1:1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 3,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "77:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 4,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "89:0:1"
|
||||
},
|
||||
"src": "67:35:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "internal"
|
||||
}
|
||||
],
|
||||
"src": "36:68:1",
|
||||
"usedErrors": []
|
||||
},
|
||||
{
|
||||
"abstract": false,
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 25,
|
||||
"name": "C",
|
||||
"nameLocation": "114:1:1",
|
||||
"nodeType": "ContractDefinition",
|
||||
"nodes":
|
||||
[
|
||||
{
|
||||
"anonymous": false,
|
||||
"id": 12,
|
||||
"name": "H",
|
||||
"nameLocation": "128:1:1",
|
||||
"nodeType": "EventDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 11,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "129:2:1"
|
||||
},
|
||||
"src": "122:10:1"
|
||||
},
|
||||
{
|
||||
"body":
|
||||
{
|
||||
"id": 23,
|
||||
"nodeType": "Block",
|
||||
"src": "157:20:1",
|
||||
"statements":
|
||||
[
|
||||
{
|
||||
"expression":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"expression":
|
||||
{
|
||||
"id": 15,
|
||||
"name": "L",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"src": "159:1:1",
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 17,
|
||||
"memberLocation": "161:1:1",
|
||||
"memberName": "f",
|
||||
"nodeType": "MemberAccess",
|
||||
"src": "159:3:1",
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 18,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "159:5:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 19,
|
||||
"nodeType": "ExpressionStatement",
|
||||
"src": "159:5:1"
|
||||
},
|
||||
{
|
||||
"eventCall":
|
||||
{
|
||||
"arguments": [],
|
||||
"expression":
|
||||
{
|
||||
"id": 20,
|
||||
"name": "H",
|
||||
"nodeType": "Identifier",
|
||||
"overloadedDeclarations": [],
|
||||
"src": "171:1:1",
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 21,
|
||||
"nameLocations": [],
|
||||
"names": [],
|
||||
"nodeType": "FunctionCall",
|
||||
"src": "171:3:1",
|
||||
"tryCall": false,
|
||||
"typeDescriptions": {}
|
||||
},
|
||||
"id": 22,
|
||||
"nodeType": "EmitStatement",
|
||||
"src": "166:8:1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"id": 24,
|
||||
"implemented": true,
|
||||
"kind": "function",
|
||||
"modifiers": [],
|
||||
"name": "g",
|
||||
"nameLocation": "146:1:1",
|
||||
"nodeType": "FunctionDefinition",
|
||||
"parameters":
|
||||
{
|
||||
"id": 13,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "147:2:1"
|
||||
},
|
||||
"returnParameters":
|
||||
{
|
||||
"id": 14,
|
||||
"nodeType": "ParameterList",
|
||||
"parameters": [],
|
||||
"src": "157:0:1"
|
||||
},
|
||||
"src": "137:40:1",
|
||||
"stateMutability": "nonpayable",
|
||||
"virtual": false,
|
||||
"visibility": "public"
|
||||
}
|
||||
],
|
||||
"src": "105:74:1",
|
||||
"usedErrors": []
|
||||
}
|
||||
],
|
||||
"src": "36:144:1"
|
||||
}
|
@ -21,6 +21,7 @@
|
||||
"canonicalName": "C1",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 1,
|
||||
"linearizedBaseContracts":
|
||||
@ -60,6 +61,7 @@
|
||||
"canonicalName": "C2",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 4,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 1,
|
||||
"name": "C1",
|
||||
"nameLocation": "9:2:1",
|
||||
@ -40,6 +41,7 @@
|
||||
],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 4,
|
||||
"name": "C2",
|
||||
"nameLocation": "24:2:1",
|
||||
|
@ -18,6 +18,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 1,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -10,6 +10,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 1,
|
||||
"name": "C",
|
||||
"nameLocation": "45:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "c",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 11,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 11,
|
||||
"name": "c",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "c",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 15,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 15,
|
||||
"name": "c",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 23,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 14,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 14,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 14,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 14,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 10,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 10,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
@ -17,6 +17,7 @@
|
||||
"canonicalName": "C",
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"fullyImplemented": true,
|
||||
"id": 15,
|
||||
"linearizedBaseContracts":
|
||||
|
@ -9,6 +9,7 @@
|
||||
"baseContracts": [],
|
||||
"contractDependencies": [],
|
||||
"contractKind": "contract",
|
||||
"emittedEvents": [],
|
||||
"id": 15,
|
||||
"name": "C",
|
||||
"nameLocation": "9:1:1",
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user