Remove/update tests

This commit is contained in:
Alex Beregszaszi 2020-11-20 15:54:53 +00:00
parent 3bce2a2294
commit c4fd7e4003
46 changed files with 165 additions and 6403 deletions

View File

@ -1 +1 @@
--error-recovery --ast-json --hashes
--error-recovery --ast-compact-json --hashes

View File

@ -1,239 +1,181 @@
JSON AST:
JSON AST (compact format):
======= recovery_ast_constructor/input.sol =======
{
"attributes":
"absolutePath": "recovery_ast_constructor/input.sol",
"exportedSymbols":
{
"absolutePath": "recovery_ast_constructor/input.sol",
"exportedSymbols":
{
"Error1":
[
18
]
},
"license": "GPL-3.0"
"Error1":
[
18
]
},
"children":
"id": 19,
"license": "GPL-3.0",
"nodeType": "SourceUnit",
"nodes":
[
{
"attributes":
{
"literals":
[
"solidity",
">=",
"0.0",
".0"
]
},
"id": 1,
"name": "PragmaDirective",
"literals":
[
"solidity",
">=",
"0.0",
".0"
],
"nodeType": "PragmaDirective",
"src": "36:24:0"
},
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
18
],
"name": "Error1",
"scope": 19
},
"children":
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "contract",
"fullyImplemented": true,
"id": 18,
"linearizedBaseContracts":
[
18
],
"name": "Error1",
"nodeType": "ContractDefinition",
"nodes":
[
{
"attributes":
"body":
{
"implemented": true,
"isConstructor": true,
"kind": "constructor",
"modifiers":
"id": 8,
"nodeType": "Block",
"src": "96:49:0",
"statements":
[
null
],
"name": "",
"scope": 18,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
]
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "93:2:0"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 3,
"name": "ParameterList",
"src": "96:0:0"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 8,
"name": "Block",
"src": "96:49:0"
}
],
"id": 9,
"name": "FunctionDefinition",
"src": "82:63:0"
"implemented": true,
"kind": "constructor",
"modifiers": [],
"name": "",
"nodeType": "FunctionDefinition",
"parameters":
{
"id": 2,
"nodeType": "ParameterList",
"parameters": [],
"src": "93:2:0"
},
"returnParameters":
{
"id": 3,
"nodeType": "ParameterList",
"parameters": [],
"src": "96:0:0"
},
"scope": 18,
"src": "82:63:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"attributes":
"body":
{
"functionSelector": "af11c34c",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
"id": 16,
"nodeType": "Block",
"src": "440:19:0",
"statements":
[
null
],
"name": "five",
"scope": 18,
"stateMutability": "view",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 10,
"name": "ParameterList",
"src": "411:2:0"
},
{
"children":
[
"expression":
{
"attributes":
"hexValue": "35",
"id": 14,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "453:1:0",
"typeDescriptions":
{
"constant": false,
"mutability": "mutable",
"name": "",
"scope": 17,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
"typeIdentifier": "t_rational_5_by_1",
"typeString": "int_const 5"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 11,
"name": "ElementaryTypeName",
"src": "434:4:0"
}
],
"id": 12,
"name": "VariableDeclaration",
"src": "434:4:0"
}
],
"id": 13,
"name": "ParameterList",
"src": "433:6:0"
},
{
"children":
[
{
"attributes":
{
"functionReturnParameters": 13
},
"children":
[
{
"attributes":
{
"hexvalue": "35",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 5",
"value": "5"
},
"id": 14,
"name": "Literal",
"src": "453:1:0"
}
],
"id": 15,
"name": "Return",
"src": "446:8:0"
}
],
"id": 16,
"name": "Block",
"src": "440:19:0"
}
],
"value": "5"
},
"functionReturnParameters": 13,
"id": 15,
"nodeType": "Return",
"src": "446:8:0"
}
]
},
"functionSelector": "af11c34c",
"id": 17,
"name": "FunctionDefinition",
"src": "398:61:0"
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "five",
"nodeType": "FunctionDefinition",
"parameters":
{
"id": 10,
"nodeType": "ParameterList",
"parameters": [],
"src": "411:2:0"
},
"returnParameters":
{
"id": 13,
"nodeType": "ParameterList",
"parameters":
[
{
"constant": false,
"id": 12,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"scope": 17,
"src": "434:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions":
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName":
{
"id": 11,
"name": "uint",
"nodeType": "ElementaryTypeName",
"src": "434:4:0",
"typeDescriptions":
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"visibility": "internal"
}
],
"src": "433:6:0"
},
"scope": 18,
"src": "398:61:0",
"stateMutability": "view",
"virtual": false,
"visibility": "public"
}
],
"id": 18,
"name": "ContractDefinition",
"scope": 19,
"src": "62:399:0"
}
],
"id": 19,
"name": "SourceUnit",
"src": "36:426:0"
}

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": [ "abi", "devdoc", "userdoc", "evm.bytecode", "evm.assembly", "evm.gasEstimates", "evm.legacyAssembly", "metadata" ],
"": [ "legacyAST" ]
"": [ "ast" ]
}
}
},

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": [ "abi", "devdoc", "userdoc", "evm.bytecode", "evm.assembly", "evm.gasEstimates", "evm.legacyAssembly", "metadata" ],
"": [ "legacyAST" ]
"": [ "ast" ]
}
}
},

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": "it's a contract, but not an array!",
"": [ "legacyAST" ]
"": [ "ast" ]
}
}
}

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": [ 1, 2, 3 ,4],
"": [ "legacyAST" ]
"": [ "ast" ]
}
}
}

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": [ "abi", "devdoc", "userdoc", "evm.bytecode", "evm.assembly", "evm.gasEstimates", "evm.legacyAssembly", "metadata" ],
"": [ "legacyAST" ]
"": [ "ast" ]
}
},
"remappings": "not an object"

View File

@ -9,7 +9,7 @@
"outputSelection": {
"fileA": {
"A": [ "abi", "devdoc", "userdoc", "evm.bytecode", "evm.assembly", "evm.gasEstimates", "evm.legacyAssembly", "metadata" ],
"": [ "legacyAST" ]
"": [ "ast" ]
}
},
"remappings": [1, 2 ,3 ,4]

View File

@ -1,109 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": true,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": true,
"kind": "constructor",
"modifiers":
[
null
],
"name": "",
"scope": 5,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "34:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "37:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "37:4:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "23:18:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:43:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:44:1"
}

View File

@ -1,611 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
39
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
39
],
"name": "C",
"scope": 40
},
"children":
[
{
"attributes":
{
"constant": false,
"functionSelector": "97682884",
"mutability": "mutable",
"name": "m",
"scope": 39,
"stateVariable": true,
"storageLocation": "default",
"type": "mapping(address => address payable)",
"visibility": "public"
},
"children":
[
{
"attributes":
{
"type": "mapping(address => address payable)"
},
"children":
[
{
"attributes":
{
"name": "address",
"type": "address"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "25:7:1"
},
{
"attributes":
{
"name": "address",
"stateMutability": "payable",
"type": "address payable"
},
"id": 2,
"name": "ElementaryTypeName",
"src": "36:15:1"
}
],
"id": 3,
"name": "Mapping",
"src": "17:35:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "17:44:1"
},
{
"attributes":
{
"functionSelector": "fc68521a",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 39,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "arg",
"scope": 38,
"stateVariable": false,
"storageLocation": "default",
"type": "address payable",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "address",
"stateMutability": "payable",
"type": "address payable"
},
"id": 5,
"name": "ElementaryTypeName",
"src": "78:15:1"
}
],
"id": 6,
"name": "VariableDeclaration",
"src": "78:19:1"
}
],
"id": 7,
"name": "ParameterList",
"src": "77:21:1"
},
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "r",
"scope": 38,
"stateVariable": false,
"storageLocation": "default",
"type": "address payable",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "address",
"stateMutability": "payable",
"type": "address payable"
},
"id": 8,
"name": "ElementaryTypeName",
"src": "115:15:1"
}
],
"id": 9,
"name": "VariableDeclaration",
"src": "115:17:1"
}
],
"id": 10,
"name": "ParameterList",
"src": "114:19:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
12
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "a",
"scope": 37,
"stateVariable": false,
"storageLocation": "default",
"type": "address payable",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "address",
"stateMutability": "payable",
"type": "address payable"
},
"id": 11,
"name": "ElementaryTypeName",
"src": "144:15:1"
}
],
"id": 12,
"name": "VariableDeclaration",
"src": "144:17:1"
},
{
"attributes":
{
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"type": "address payable"
},
"children":
[
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 4,
"type": "mapping(address => address payable)",
"value": "m"
},
"id": 13,
"name": "Identifier",
"src": "164:1:1"
},
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 6,
"type": "address payable",
"value": "arg"
},
"id": 14,
"name": "Identifier",
"src": "166:3:1"
}
],
"id": 15,
"name": "IndexAccess",
"src": "164:6:1"
}
],
"id": 16,
"name": "VariableDeclarationStatement",
"src": "144:26:1"
},
{
"children":
[
{
"attributes":
{
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"operator": "=",
"type": "address payable"
},
"children":
[
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 9,
"type": "address payable",
"value": "r"
},
"id": 17,
"name": "Identifier",
"src": "180:1:1"
},
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 6,
"type": "address payable",
"value": "arg"
},
"id": 18,
"name": "Identifier",
"src": "184:3:1"
}
],
"id": 19,
"name": "Assignment",
"src": "180:7:1"
}
],
"id": 20,
"name": "ExpressionStatement",
"src": "180:7:1"
},
{
"attributes":
{
"assignments":
[
22
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "c",
"scope": 37,
"stateVariable": false,
"storageLocation": "default",
"type": "address",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "address",
"stateMutability": "nonpayable",
"type": "address"
},
"id": 21,
"name": "ElementaryTypeName",
"src": "197:7:1"
}
],
"id": 22,
"name": "VariableDeclaration",
"src": "197:9:1"
},
{
"attributes":
{
"isConstant": false,
"isLValue": false,
"isPure": false,
"isStructConstructorCall": false,
"lValueRequested": false,
"names":
[
null
],
"tryCall": false,
"type": "address",
"type_conversion": true
},
"children":
[
{
"attributes":
{
"argumentTypes":
[
{
"typeIdentifier": "t_contract$_C_$39",
"typeString": "contract C"
}
],
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"type": "type(address)"
},
"children":
[
{
"attributes":
{
"name": "address"
},
"id": 23,
"name": "ElementaryTypeName",
"src": "209:7:1"
}
],
"id": 24,
"name": "ElementaryTypeNameExpression",
"src": "209:7:1"
},
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": -28,
"type": "contract C",
"value": "this"
},
"id": 25,
"name": "Identifier",
"src": "217:4:1"
}
],
"id": 26,
"name": "FunctionCall",
"src": "209:13:1"
}
],
"id": 27,
"name": "VariableDeclarationStatement",
"src": "197:25:1"
},
{
"children":
[
{
"attributes":
{
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"operator": "=",
"type": "address payable"
},
"children":
[
{
"attributes":
{
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"type": "address payable"
},
"children":
[
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 4,
"type": "mapping(address => address payable)",
"value": "m"
},
"id": 28,
"name": "Identifier",
"src": "232:1:1"
},
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 22,
"type": "address",
"value": "c"
},
"id": 29,
"name": "Identifier",
"src": "234:1:1"
}
],
"id": 30,
"name": "IndexAccess",
"src": "232:4:1"
},
{
"attributes":
{
"isConstant": false,
"isLValue": false,
"isPure": true,
"isStructConstructorCall": false,
"lValueRequested": false,
"names":
[
null
],
"tryCall": false,
"type": "address payable",
"type_conversion": true
},
"children":
[
{
"attributes":
{
"argumentTypes":
[
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
}
],
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"type": "type(address)"
},
"children":
[
{
"attributes":
{
"name": "address"
},
"id": 31,
"name": "ElementaryTypeName",
"src": "239:7:1"
}
],
"id": 32,
"name": "ElementaryTypeNameExpression",
"src": "239:7:1"
},
{
"attributes":
{
"hexvalue": "30",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 0",
"value": "0"
},
"id": 33,
"name": "Literal",
"src": "247:1:1"
}
],
"id": 34,
"name": "FunctionCall",
"src": "239:10:1"
}
],
"id": 35,
"name": "Assignment",
"src": "232:17:1"
}
],
"id": 36,
"name": "ExpressionStatement",
"src": "232:17:1"
}
],
"id": 37,
"name": "Block",
"src": "134:122:1"
}
],
"id": 38,
"name": "FunctionDefinition",
"src": "67:189:1"
}
],
"id": 39,
"name": "ContractDefinition",
"src": "0:258:1"
}
],
"id": 40,
"name": "SourceUnit",
"src": "0:259:1"
}

View File

@ -1,88 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
4
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
4
],
"name": "C",
"scope": 5
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "i",
"scope": 4,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256[]",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "uint256[]"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "13:4:1"
}
],
"id": 2,
"name": "ArrayTypeName",
"src": "13:6:1"
}
],
"id": 3,
"name": "VariableDeclaration",
"src": "13:8:1"
}
],
"id": 4,
"name": "ContractDefinition",
"src": "0:24:1"
}
],
"id": 5,
"name": "SourceUnit",
"src": "0:25:1"
}

View File

@ -1,109 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": true,
"kind": "constructor",
"modifiers":
[
null
],
"name": "",
"scope": 5,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "25:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "28:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "28:4:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "14:18:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:34:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:35:1"
}

View File

@ -1,268 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"A":
[
1
],
"B":
[
4
],
"C":
[
7
],
"D":
[
10
],
"E":
[
13
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
1
],
"name": "A",
"nodes":
[
null
],
"scope": 14
},
"id": 1,
"name": "ContractDefinition",
"src": "0:14:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
1
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
4,
1
],
"name": "B",
"nodes":
[
null
],
"scope": 14
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "A",
"referencedDeclaration": 1
},
"id": 2,
"name": "IdentifierPath",
"src": "29:1:1"
}
],
"id": 3,
"name": "InheritanceSpecifier",
"src": "29:1:1"
}
],
"id": 4,
"name": "ContractDefinition",
"src": "15:19:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
1,
4
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
7,
4,
1
],
"name": "C",
"nodes":
[
null
],
"scope": 14
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "B",
"referencedDeclaration": 4
},
"id": 5,
"name": "IdentifierPath",
"src": "49:1:1"
}
],
"id": 6,
"name": "InheritanceSpecifier",
"src": "49:1:1"
}
],
"id": 7,
"name": "ContractDefinition",
"src": "35:19:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
1,
4,
7
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
10,
7,
4,
1
],
"name": "D",
"nodes":
[
null
],
"scope": 14
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "C",
"referencedDeclaration": 7
},
"id": 8,
"name": "IdentifierPath",
"src": "69:1:1"
}
],
"id": 9,
"name": "InheritanceSpecifier",
"src": "69:1:1"
}
],
"id": 10,
"name": "ContractDefinition",
"src": "55:19:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
1,
4,
7,
10
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
13,
10,
7,
4,
1
],
"name": "E",
"nodes":
[
null
],
"scope": 14
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "D",
"referencedDeclaration": 10
},
"id": 11,
"name": "IdentifierPath",
"src": "89:1:1"
}
],
"id": 12,
"name": "InheritanceSpecifier",
"src": "89:1:1"
}
],
"id": 13,
"name": "ContractDefinition",
"src": "75:19:1"
}
],
"id": 14,
"name": "SourceUnit",
"src": "0:95:1"
}

View File

@ -1,364 +0,0 @@
[
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
2
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
2
],
"name": "C",
"nodes":
[
null
],
"scope": 3
},
"children":
[
{
"attributes":
{
"text": "This contract is empty"
},
"id": 1,
"name": "StructuredDocumentation",
"src": "0:27:1"
}
],
"id": 2,
"name": "ContractDefinition",
"src": "28:13:1"
}
],
"id": 3,
"name": "SourceUnit",
"src": "28:14:1"
},
{
"attributes":
{
"absolutePath": "b",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"nodes":
[
null
],
"scope": 6
},
"children":
[
{
"attributes":
{
"text": "This contract is empty\nand has a line-breaking comment."
},
"id": 4,
"name": "StructuredDocumentation",
"src": "0:61:2"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "62:13:2"
}
],
"id": 6,
"name": "SourceUnit",
"src": "62:14:2"
},
{
"attributes":
{
"absolutePath": "c",
"exportedSymbols":
{
"C":
[
23
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
23
],
"name": "C",
"scope": 24
},
"children":
[
{
"attributes":
{
"constant": false,
"functionSelector": "c19d93fb",
"mutability": "mutable",
"name": "state",
"scope": 23,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256",
"visibility": "public"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 8,
"name": "ElementaryTypeName",
"src": "48:4:3"
},
{
"attributes":
{
"text": "Some comment on state var."
},
"id": 7,
"name": "StructuredDocumentation",
"src": "15:32:3"
}
],
"id": 9,
"name": "VariableDeclaration",
"src": "48:17:3"
},
{
"attributes":
{
"anonymous": false,
"name": "Evt"
},
"children":
[
{
"attributes":
{
"text": "Some comment on Evt."
},
"id": 10,
"name": "StructuredDocumentation",
"src": "69:26:3"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 11,
"name": "ParameterList",
"src": "105:2:3"
}
],
"id": 12,
"name": "EventDefinition",
"src": "96:12:3"
},
{
"attributes":
{
"name": "mod",
"virtual": false,
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"text": "Some comment on mod."
},
"id": 13,
"name": "StructuredDocumentation",
"src": "111:26:3"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 14,
"name": "ParameterList",
"src": "150:2:3"
},
{
"children":
[
{
"id": 15,
"name": "PlaceholderStatement",
"src": "155:1:3"
}
],
"id": 16,
"name": "Block",
"src": "153:6:3"
}
],
"id": 17,
"name": "ModifierDefinition",
"src": "138:21:3"
},
{
"attributes":
{
"functionSelector": "a4a2c40b",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "fn",
"scope": 23,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"text": "Some comment on fn."
},
"id": 18,
"name": "StructuredDocumentation",
"src": "162:25:3"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 19,
"name": "ParameterList",
"src": "199:2:3"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 20,
"name": "ParameterList",
"src": "209:0:3"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 21,
"name": "Block",
"src": "209:2:3"
}
],
"id": 22,
"name": "FunctionDefinition",
"src": "188:23:3"
}
],
"id": 23,
"name": "ContractDefinition",
"src": "0:213:3"
}
],
"id": 24,
"name": "SourceUnit",
"src": "0:214:3"
}
]

View File

@ -1,78 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
4
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
4
],
"name": "C",
"scope": 5
},
"children":
[
{
"attributes":
{
"canonicalName": "C.E",
"name": "E"
},
"children":
[
{
"attributes":
{
"name": "A"
},
"id": 1,
"name": "EnumValue",
"src": "22:1:1"
},
{
"attributes":
{
"name": "B"
},
"id": 2,
"name": "EnumValue",
"src": "25:1:1"
}
],
"id": 3,
"name": "EnumDefinition",
"src": "13:15:1"
}
],
"id": 4,
"name": "ContractDefinition",
"src": "0:30:1"
}
],
"id": 5,
"name": "SourceUnit",
"src": "0:31:1"
}

View File

@ -1,73 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
3
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
3
],
"name": "C",
"scope": 4
},
"children":
[
{
"attributes":
{
"anonymous": false,
"name": "E"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "20:2:1"
}
],
"id": 2,
"name": "EventDefinition",
"src": "13:10:1"
}
],
"id": 3,
"name": "ContractDefinition",
"src": "0:25:1"
}
],
"id": 4,
"name": "SourceUnit",
"src": "0:26:1"
}

View File

@ -1,171 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
9
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
9
],
"name": "C",
"scope": 10
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": false,
"kind": "receive",
"modifiers":
[
null
],
"name": "",
"scope": 9,
"stateMutability": "payable",
"virtual": false,
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "22:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "42:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "42:5:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "15:32:1"
},
{
"attributes":
{
"implemented": true,
"isConstructor": false,
"kind": "fallback",
"modifiers":
[
null
],
"name": "",
"scope": 9,
"stateMutability": "payable",
"virtual": false,
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 5,
"name": "ParameterList",
"src": "58:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 6,
"name": "ParameterList",
"src": "78:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 7,
"name": "Block",
"src": "78:5:1"
}
],
"id": 8,
"name": "FunctionDefinition",
"src": "50:33:1"
}
],
"id": 9,
"name": "ContractDefinition",
"src": "0:85:1"
}
],
"id": 10,
"name": "SourceUnit",
"src": "0:86:1"
}

View File

@ -1,109 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": false,
"kind": "fallback",
"modifiers":
[
null
],
"name": "",
"scope": 5,
"stateMutability": "payable",
"virtual": false,
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "43:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "43:5:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "15:33:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:50:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:51:1"
}

View File

@ -1,109 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": false,
"kind": "fallback",
"modifiers":
[
null
],
"name": "",
"scope": 5,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "22:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "34:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "34:2:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "14:22:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:38:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:39:1"
}

View File

@ -1,266 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
17
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
17
],
"name": "C",
"scope": 18
},
"children":
[
{
"attributes":
{
"functionSelector": "d6cd4974",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 17,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 16,
"stateVariable": false,
"storageLocation": "default",
"type": "function () payable external returns (uint256)",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"stateMutability": "payable",
"type": "function () payable external returns (uint256)",
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "32:2:1"
},
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "",
"scope": 5,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 2,
"name": "ElementaryTypeName",
"src": "61:4:1"
}
],
"id": 3,
"name": "VariableDeclaration",
"src": "61:4:1"
}
],
"id": 4,
"name": "ParameterList",
"src": "60:6:1"
}
],
"id": 5,
"name": "FunctionTypeName",
"src": "24:44:1"
}
],
"id": 6,
"name": "VariableDeclaration",
"src": "24:44:1"
}
],
"id": 7,
"name": "ParameterList",
"src": "23:46:1"
},
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "",
"scope": 16,
"stateVariable": false,
"storageLocation": "default",
"type": "function () view external returns (uint256)",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"stateMutability": "view",
"type": "function () view external returns (uint256)",
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 8,
"name": "ParameterList",
"src": "87:2:1"
},
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "",
"scope": 12,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 9,
"name": "ElementaryTypeName",
"src": "113:4:1"
}
],
"id": 10,
"name": "VariableDeclaration",
"src": "113:4:1"
}
],
"id": 11,
"name": "ParameterList",
"src": "112:6:1"
}
],
"id": 12,
"name": "FunctionTypeName",
"src": "79:40:1"
}
],
"id": 13,
"name": "VariableDeclaration",
"src": "79:40:1"
}
],
"id": 14,
"name": "ParameterList",
"src": "78:41:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 15,
"name": "Block",
"src": "120:2:1"
}
],
"id": 16,
"name": "FunctionDefinition",
"src": "13:109:1"
}
],
"id": 17,
"name": "ContractDefinition",
"src": "0:124:1"
}
],
"id": 18,
"name": "SourceUnit",
"src": "0:125:1"
}

View File

@ -1,41 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"E":
[
2
]
}
},
"children":
[
{
"attributes":
{
"canonicalName": "E",
"name": "E"
},
"children":
[
{
"attributes":
{
"name": "A"
},
"id": 1,
"name": "EnumValue",
"src": "9:1:1"
}
],
"id": 2,
"name": "EnumDefinition",
"src": "0:12:1"
}
],
"id": 3,
"name": "SourceUnit",
"src": "0:13:1"
}

View File

@ -1,63 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"S":
[
3
]
}
},
"children":
[
{
"attributes":
{
"canonicalName": "S",
"name": "S",
"scope": 4,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "a",
"scope": 3,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint256",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "11:7:1"
}
],
"id": 2,
"name": "VariableDeclaration",
"src": "11:9:1"
}
],
"id": 3,
"name": "StructDefinition",
"src": "0:23:1"
}
],
"id": 4,
"name": "SourceUnit",
"src": "0:24:1"
}

View File

@ -1,100 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C1":
[
1
],
"C2":
[
4
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
1
],
"name": "C1",
"nodes":
[
null
],
"scope": 5
},
"id": 1,
"name": "ContractDefinition",
"src": "0:14:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
1
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
4,
1
],
"name": "C2",
"nodes":
[
null
],
"scope": 5
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "C1",
"referencedDeclaration": 1
},
"id": 2,
"name": "IdentifierPath",
"src": "30:2:1"
}
],
"id": 3,
"name": "InheritanceSpecifier",
"src": "30:2:1"
}
],
"id": 4,
"name": "ContractDefinition",
"src": "15:20:1"
}
],
"id": 5,
"name": "SourceUnit",
"src": "0:36:1"
}

View File

@ -1,49 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
1
]
},
"license": "GPL-3.0"
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
1
],
"name": "C",
"nodes":
[
null
],
"scope": 2
},
"id": 1,
"name": "ContractDefinition",
"src": "36:13:1"
}
],
"id": 2,
"name": "SourceUnit",
"src": "36:14:1"
}

View File

@ -1,203 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"c":
[
11
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
11
],
"name": "c",
"scope": 12
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 11,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
4
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "a",
"scope": 9,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "35:4:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "35:6:1"
},
{
"attributes":
{
"commonType":
{
"typeIdentifier": "t_rational_5_by_1",
"typeString": "int_const 5"
},
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"operator": "+",
"type": "int_const 5"
},
"children":
[
{
"attributes":
{
"hexvalue": "32",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 2",
"value": "2"
},
"id": 5,
"name": "Literal",
"src": "44:1:1"
},
{
"attributes":
{
"hexvalue": "33",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 3",
"value": "3"
},
"id": 6,
"name": "Literal",
"src": "48:1:1"
}
],
"id": 7,
"name": "BinaryOperation",
"src": "44:5:1"
}
],
"id": 8,
"name": "VariableDeclarationStatement",
"src": "35:14:1"
}
],
"id": 9,
"name": "Block",
"src": "33:19:1"
}
],
"id": 10,
"name": "FunctionDefinition",
"src": "13:39:1"
}
],
"id": 11,
"name": "ContractDefinition",
"src": "0:54:1"
}
],
"id": 12,
"name": "SourceUnit",
"src": "0:55:1"
}

View File

@ -1,217 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"c":
[
15
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
15
],
"name": "c",
"scope": 16
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "a",
"scope": 15,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256[]",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "uint256[]"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "13:4:1"
}
],
"id": 2,
"name": "ArrayTypeName",
"src": "13:6:1"
}
],
"id": 3,
"name": "VariableDeclaration",
"src": "13:8:1"
},
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 15,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 4,
"name": "ParameterList",
"src": "33:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 5,
"name": "ParameterList",
"src": "43:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
10
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "b",
"scope": 13,
"stateVariable": false,
"storageLocation": "storage",
"type": "uint256[]",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "uint256[]"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 8,
"name": "ElementaryTypeName",
"src": "45:4:1"
}
],
"id": 9,
"name": "ArrayTypeName",
"src": "45:6:1"
}
],
"id": 10,
"name": "VariableDeclaration",
"src": "45:16:1"
},
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 3,
"type": "uint256[] storage ref",
"value": "a"
},
"id": 11,
"name": "Identifier",
"src": "64:1:1"
}
],
"id": 12,
"name": "VariableDeclarationStatement",
"src": "45:20:1"
}
],
"id": 13,
"name": "Block",
"src": "43:25:1"
}
],
"id": 14,
"name": "FunctionDefinition",
"src": "23:45:1"
}
],
"id": 15,
"name": "ContractDefinition",
"src": "0:70:1"
}
],
"id": 16,
"name": "SourceUnit",
"src": "0:71:1"
}

View File

@ -1,266 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
19
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
19
],
"name": "C",
"scope": 20
},
"children":
[
{
"attributes":
{
"canonicalName": "C.E",
"name": "E"
},
"children":
[
{
"attributes":
{
"name": "A"
},
"id": 1,
"name": "EnumValue",
"src": "26:1:1"
},
{
"attributes":
{
"name": "B"
},
"id": 2,
"name": "EnumValue",
"src": "29:1:1"
},
{
"attributes":
{
"name": "C"
},
"id": 3,
"name": "EnumValue",
"src": "32:1:1"
}
],
"id": 4,
"name": "EnumDefinition",
"src": "17:18:1"
},
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "a",
"scope": 19,
"stateVariable": true,
"storageLocation": "default",
"type": "mapping(contract C => bool)",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "mapping(contract C => bool)"
},
"children":
[
{
"attributes":
{
"referencedDeclaration": 19,
"type": "contract C"
},
"children":
[
{
"attributes":
{
"name": "C",
"referencedDeclaration": 19
},
"id": 5,
"name": "IdentifierPath",
"src": "48:1:1"
}
],
"id": 6,
"name": "UserDefinedTypeName",
"src": "48:1:1"
},
{
"attributes":
{
"name": "bool",
"type": "bool"
},
"id": 7,
"name": "ElementaryTypeName",
"src": "53:4:1"
}
],
"id": 8,
"name": "Mapping",
"src": "40:18:1"
}
],
"id": 9,
"name": "VariableDeclaration",
"src": "40:20:1"
},
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "b",
"scope": 19,
"stateVariable": true,
"storageLocation": "default",
"type": "mapping(address => bool)",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "mapping(address => bool)"
},
"children":
[
{
"attributes":
{
"name": "address",
"type": "address"
},
"id": 10,
"name": "ElementaryTypeName",
"src": "74:7:1"
},
{
"attributes":
{
"name": "bool",
"type": "bool"
},
"id": 11,
"name": "ElementaryTypeName",
"src": "85:4:1"
}
],
"id": 12,
"name": "Mapping",
"src": "66:24:1"
}
],
"id": 13,
"name": "VariableDeclaration",
"src": "66:26:1"
},
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "c",
"scope": 19,
"stateVariable": true,
"storageLocation": "default",
"type": "mapping(enum C.E => bool)",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "mapping(enum C.E => bool)"
},
"children":
[
{
"attributes":
{
"referencedDeclaration": 4,
"type": "enum C.E"
},
"children":
[
{
"attributes":
{
"name": "E",
"referencedDeclaration": 4
},
"id": 14,
"name": "IdentifierPath",
"src": "106:1:1"
}
],
"id": 15,
"name": "UserDefinedTypeName",
"src": "106:1:1"
},
{
"attributes":
{
"name": "bool",
"type": "bool"
},
"id": 16,
"name": "ElementaryTypeName",
"src": "111:4:1"
}
],
"id": 17,
"name": "Mapping",
"src": "98:18:1"
}
],
"id": 18,
"name": "VariableDeclaration",
"src": "98:20:1"
}
],
"id": 19,
"name": "ContractDefinition",
"src": "0:121:1"
}
],
"id": 20,
"name": "SourceUnit",
"src": "0:122:1"
}

View File

@ -1,204 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
14
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
14
],
"name": "C",
"scope": 15
},
"children":
[
{
"attributes":
{
"name": "M",
"virtual": false,
"visibility": "internal"
},
"children":
[
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "i",
"scope": 6,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "24:4:1"
}
],
"id": 2,
"name": "VariableDeclaration",
"src": "24:6:1"
}
],
"id": 3,
"name": "ParameterList",
"src": "23:8:1"
},
{
"children":
[
{
"id": 4,
"name": "PlaceholderStatement",
"src": "34:1:1"
}
],
"id": 5,
"name": "Block",
"src": "32:6:1"
}
],
"id": 6,
"name": "ModifierDefinition",
"src": "13:25:1"
},
{
"attributes":
{
"functionSelector": "28811f59",
"implemented": true,
"isConstructor": false,
"kind": "function",
"name": "F",
"scope": 14,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 7,
"name": "ParameterList",
"src": "49:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 11,
"name": "ParameterList",
"src": "64:0:1"
},
{
"children":
[
{
"attributes":
{
"name": "M",
"referencedDeclaration": 6
},
"id": 8,
"name": "IdentifierPath",
"src": "52:1:1"
},
{
"attributes":
{
"hexvalue": "31",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 1",
"value": "1"
},
"id": 9,
"name": "Literal",
"src": "54:1:1"
}
],
"id": 10,
"name": "ModifierInvocation",
"src": "52:4:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 12,
"name": "Block",
"src": "64:2:1"
}
],
"id": 13,
"name": "FunctionDefinition",
"src": "39:27:1"
}
],
"id": 14,
"name": "ContractDefinition",
"src": "0:68:1"
}
],
"id": 15,
"name": "SourceUnit",
"src": "0:69:1"
}

View File

@ -1,204 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
14
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
14
],
"name": "C",
"scope": 15
},
"children":
[
{
"attributes":
{
"name": "M",
"virtual": false,
"visibility": "internal"
},
"children":
[
{
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "i",
"scope": 6,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "24:4:1"
}
],
"id": 2,
"name": "VariableDeclaration",
"src": "24:6:1"
}
],
"id": 3,
"name": "ParameterList",
"src": "23:8:1"
},
{
"children":
[
{
"id": 4,
"name": "PlaceholderStatement",
"src": "34:1:1"
}
],
"id": 5,
"name": "Block",
"src": "32:6:1"
}
],
"id": 6,
"name": "ModifierDefinition",
"src": "13:25:1"
},
{
"attributes":
{
"functionSelector": "28811f59",
"implemented": true,
"isConstructor": false,
"kind": "function",
"name": "F",
"scope": 14,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 7,
"name": "ParameterList",
"src": "49:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 11,
"name": "ParameterList",
"src": "64:0:1"
},
{
"children":
[
{
"attributes":
{
"name": "M",
"referencedDeclaration": 6
},
"id": 8,
"name": "IdentifierPath",
"src": "52:1:1"
},
{
"attributes":
{
"hexvalue": "31",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 1",
"value": "1"
},
"id": 9,
"name": "Literal",
"src": "54:1:1"
}
],
"id": 10,
"name": "ModifierInvocation",
"src": "52:4:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 12,
"name": "Block",
"src": "64:2:1"
}
],
"id": 13,
"name": "FunctionDefinition",
"src": "39:27:1"
}
],
"id": 14,
"name": "ContractDefinition",
"src": "0:68:1"
}
],
"id": 15,
"name": "SourceUnit",
"src": "0:69:1"
}

View File

@ -1,185 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
10
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
10
],
"name": "C",
"scope": 11
},
"children":
[
{
"attributes":
{
"constant": false,
"functionSelector": "0dbe671f",
"mutability": "immutable",
"name": "a",
"scope": 10,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256",
"visibility": "public"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 1,
"name": "ElementaryTypeName",
"src": "17:4:1"
},
{
"attributes":
{
"hexvalue": "34",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 4",
"value": "4"
},
"id": 2,
"name": "Literal",
"src": "43:1:1"
}
],
"id": 3,
"name": "VariableDeclaration",
"src": "17:27:1"
},
{
"attributes":
{
"constant": true,
"functionSelector": "4df7e3d0",
"mutability": "constant",
"name": "b",
"scope": 10,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256",
"visibility": "public"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 4,
"name": "ElementaryTypeName",
"src": "50:4:1"
},
{
"attributes":
{
"hexvalue": "32",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 2",
"value": "2"
},
"id": 5,
"name": "Literal",
"src": "75:1:1"
}
],
"id": 6,
"name": "VariableDeclaration",
"src": "50:26:1"
},
{
"attributes":
{
"constant": false,
"functionSelector": "c3da42b8",
"mutability": "mutable",
"name": "c",
"scope": 10,
"stateVariable": true,
"storageLocation": "default",
"type": "uint256",
"visibility": "public"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 7,
"name": "ElementaryTypeName",
"src": "82:4:1"
},
{
"attributes":
{
"hexvalue": "33",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 3",
"value": "3"
},
"id": 8,
"name": "Literal",
"src": "98:1:1"
}
],
"id": 9,
"name": "VariableDeclaration",
"src": "82:17:1"
}
],
"id": 10,
"name": "ContractDefinition",
"src": "0:102:1"
}
],
"id": 11,
"name": "SourceUnit",
"src": "0:103:1"
}

View File

@ -1,164 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
9
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
9
],
"name": "C",
"scope": 10
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 9,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
4
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 7,
"stateVariable": false,
"storageLocation": "memory",
"type": "string",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "string",
"type": "string"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "35:6:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "35:15:1"
},
{
"attributes":
{
"hexvalue": "ff",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "hexString",
"type": "literal_string hex\"ff\""
},
"id": 5,
"name": "Literal",
"src": "53:7:1"
}
],
"id": 6,
"name": "VariableDeclarationStatement",
"src": "35:25:1"
}
],
"id": 7,
"name": "Block",
"src": "33:30:1"
}
],
"id": 8,
"name": "FunctionDefinition",
"src": "13:50:1"
}
],
"id": 9,
"name": "ContractDefinition",
"src": "0:65:1"
}
],
"id": 10,
"name": "SourceUnit",
"src": "0:66:1"
}

View File

@ -1,511 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"A":
[
5
],
"B":
[
16
],
"C":
[
31
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "A",
"scope": 32
},
"children":
[
{
"attributes":
{
"functionSelector": "a399b6a2",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "faa",
"scope": 5,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "26:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "36:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "36:2:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "14:24:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:40:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
5
],
"contractKind": "contract",
"fullyImplemented": false,
"linearizedBaseContracts":
[
16,
5
],
"name": "B",
"scope": 32
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "A",
"referencedDeclaration": 5
},
"id": 6,
"name": "IdentifierPath",
"src": "55:1:1"
}
],
"id": 7,
"name": "InheritanceSpecifier",
"src": "55:1:1"
},
{
"attributes":
{
"functionSelector": "c2985578",
"implemented": false,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "foo",
"scope": 16,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 8,
"name": "ParameterList",
"src": "72:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 9,
"name": "ParameterList",
"src": "81:0:1"
}
],
"id": 10,
"name": "FunctionDefinition",
"src": "60:22:1"
},
{
"attributes":
{
"baseFunctions":
[
4
],
"functionSelector": "a399b6a2",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "faa",
"scope": 16,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"overrides":
[
null
]
},
"id": 12,
"name": "OverrideSpecifier",
"src": "106:8:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 11,
"name": "ParameterList",
"src": "96:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 13,
"name": "ParameterList",
"src": "115:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 14,
"name": "Block",
"src": "115:2:1"
}
],
"id": 15,
"name": "FunctionDefinition",
"src": "84:33:1"
}
],
"id": 16,
"name": "ContractDefinition",
"src": "41:78:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
5,
16
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
31,
16,
5
],
"name": "C",
"scope": 32
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "B",
"referencedDeclaration": 16
},
"id": 17,
"name": "IdentifierPath",
"src": "134:1:1"
}
],
"id": 18,
"name": "InheritanceSpecifier",
"src": "134:1:1"
},
{
"attributes":
{
"baseFunctions":
[
10
],
"functionSelector": "c2985578",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "foo",
"scope": 31,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"overrides":
[
null
]
},
"id": 20,
"name": "OverrideSpecifier",
"src": "161:8:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 19,
"name": "ParameterList",
"src": "151:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 21,
"name": "ParameterList",
"src": "170:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 22,
"name": "Block",
"src": "170:3:1"
}
],
"id": 23,
"name": "FunctionDefinition",
"src": "139:34:1"
},
{
"attributes":
{
"baseFunctions":
[
15
],
"functionSelector": "a399b6a2",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "faa",
"scope": 31,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"children":
[
{
"attributes":
{
"name": "A",
"referencedDeclaration": 5
},
"id": 25,
"name": "IdentifierPath",
"src": "206:1:1"
},
{
"attributes":
{
"name": "B",
"referencedDeclaration": 16
},
"id": 26,
"name": "IdentifierPath",
"src": "209:1:1"
}
],
"id": 27,
"name": "OverrideSpecifier",
"src": "197:14:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 24,
"name": "ParameterList",
"src": "187:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 28,
"name": "ParameterList",
"src": "212:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 29,
"name": "Block",
"src": "212:2:1"
}
],
"id": 30,
"name": "FunctionDefinition",
"src": "175:39:1"
}
],
"id": 31,
"name": "ContractDefinition",
"src": "120:96:1"
}
],
"id": 32,
"name": "SourceUnit",
"src": "0:217:1"
}

View File

@ -1,87 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"name": "M",
"virtual": false,
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "24:0:1"
},
{
"children":
[
{
"id": 2,
"name": "PlaceholderStatement",
"src": "26:1:1"
}
],
"id": 3,
"name": "Block",
"src": "24:6:1"
}
],
"id": 4,
"name": "ModifierDefinition",
"src": "13:17:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:32:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:33:1"
}

View File

@ -1,109 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"attributes":
{
"implemented": true,
"isConstructor": false,
"kind": "receive",
"modifiers":
[
null
],
"name": "",
"scope": 5,
"stateMutability": "payable",
"virtual": false,
"visibility": "external"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "22:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "42:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "42:5:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "15:32:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:49:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:50:1"
}

View File

@ -1,161 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"c":
[
11
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
11
],
"name": "c",
"scope": 12
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 11,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
7
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 9,
"stateVariable": false,
"storageLocation": "memory",
"type": "uint256[]",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "uint256[]"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 5,
"name": "ElementaryTypeName",
"src": "35:4:1"
}
],
"id": 6,
"name": "ArrayTypeName",
"src": "35:6:1"
}
],
"id": 7,
"name": "VariableDeclaration",
"src": "35:15:1"
}
],
"id": 8,
"name": "VariableDeclarationStatement",
"src": "35:15:1"
}
],
"id": 9,
"name": "Block",
"src": "33:20:1"
}
],
"id": 10,
"name": "FunctionDefinition",
"src": "13:40:1"
}
],
"id": 11,
"name": "ContractDefinition",
"src": "0:55:1"
}
],
"id": 12,
"name": "SourceUnit",
"src": "0:56:1"
}

View File

@ -1,173 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"c":
[
12
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
12
],
"name": "c",
"scope": 13
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 12,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
8
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "rows",
"scope": 10,
"stateVariable": false,
"storageLocation": "memory",
"type": "uint256[][]",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"type": "uint256[][]"
},
"children":
[
{
"attributes":
{
"type": "uint256[]"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 5,
"name": "ElementaryTypeName",
"src": "35:4:1"
}
],
"id": 6,
"name": "ArrayTypeName",
"src": "35:6:1"
}
],
"id": 7,
"name": "ArrayTypeName",
"src": "35:8:1"
}
],
"id": 8,
"name": "VariableDeclaration",
"src": "35:20:1"
}
],
"id": 9,
"name": "VariableDeclarationStatement",
"src": "35:20:1"
}
],
"id": 10,
"name": "Block",
"src": "33:25:1"
}
],
"id": 11,
"name": "FunctionDefinition",
"src": "13:45:1"
}
],
"id": 12,
"name": "ContractDefinition",
"src": "0:60:1"
}
],
"id": 13,
"name": "SourceUnit",
"src": "0:61:1"
}

View File

@ -1,48 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
1
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
1
],
"name": "C",
"nodes":
[
null
],
"scope": 2
},
"id": 1,
"name": "ContractDefinition",
"src": "0:13:1"
}
],
"id": 2,
"name": "SourceUnit",
"src": "0:14:1"
}

View File

@ -1,206 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
12
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
12
],
"name": "C",
"scope": 13
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 12,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "26:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
4
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 10,
"stateVariable": false,
"storageLocation": "default",
"type": "uint256",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "28:4:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "28:6:1"
},
{
"attributes":
{
"hexvalue": "32",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "number",
"type": "int_const 2",
"value": "2"
},
"id": 5,
"name": "Literal",
"src": "37:1:1"
}
],
"id": 6,
"name": "VariableDeclarationStatement",
"src": "28:10:1"
},
{
"children":
[
{
"attributes":
{
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"operator": "++",
"prefix": false,
"type": "uint256"
},
"children":
[
{
"attributes":
{
"overloadedDeclarations":
[
null
],
"referencedDeclaration": 4,
"type": "uint256",
"value": "x"
},
"id": 7,
"name": "Identifier",
"src": "40:1:1"
}
],
"id": 8,
"name": "UnaryOperation",
"src": "40:3:1"
}
],
"id": 9,
"name": "ExpressionStatement",
"src": "40:3:1"
}
],
"id": 10,
"name": "Block",
"src": "26:20:1"
}
],
"id": 11,
"name": "FunctionDefinition",
"src": "13:33:1"
}
],
"id": 12,
"name": "ContractDefinition",
"src": "0:48:1"
}
],
"id": 13,
"name": "SourceUnit",
"src": "0:49:1"
}

View File

@ -1,165 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
9
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
9
],
"name": "C",
"scope": 10
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 9,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
4
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 7,
"stateVariable": false,
"storageLocation": "memory",
"type": "string",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "string",
"type": "string"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "35:6:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "35:15:1"
},
{
"attributes":
{
"hexvalue": "48656c6c6f20576f726c64",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "string",
"type": "literal_string \"Hello World\"",
"value": "Hello World"
},
"id": 5,
"name": "Literal",
"src": "53:13:1"
}
],
"id": 6,
"name": "VariableDeclarationStatement",
"src": "35:31:1"
}
],
"id": 7,
"name": "Block",
"src": "33:36:1"
}
],
"id": 8,
"name": "FunctionDefinition",
"src": "13:56:1"
}
],
"id": 9,
"name": "ContractDefinition",
"src": "0:71:1"
}
],
"id": 10,
"name": "SourceUnit",
"src": "0:72:1"
}

View File

@ -1,370 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"A":
[
5
],
"B":
[
10
],
"C":
[
22
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "A",
"scope": 23
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 5,
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "27:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "45:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 3,
"name": "Block",
"src": "45:2:1"
}
],
"id": 4,
"name": "FunctionDefinition",
"src": "17:30:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "0:49:1"
},
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
10
],
"name": "B",
"scope": 23
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 10,
"stateMutability": "nonpayable",
"virtual": true,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 6,
"name": "ParameterList",
"src": "77:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 7,
"name": "ParameterList",
"src": "95:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 8,
"name": "Block",
"src": "95:2:1"
}
],
"id": 9,
"name": "FunctionDefinition",
"src": "67:30:1"
}
],
"id": 10,
"name": "ContractDefinition",
"src": "50:49:1"
},
{
"attributes":
{
"abstract": false,
"contractDependencies":
[
5,
10
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
22,
10,
5
],
"name": "C",
"scope": 23
},
"children":
[
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "A",
"referencedDeclaration": 5
},
"id": 11,
"name": "IdentifierPath",
"src": "114:1:1"
}
],
"id": 12,
"name": "InheritanceSpecifier",
"src": "114:1:1"
},
{
"attributes": {},
"children":
[
{
"attributes":
{
"name": "B",
"referencedDeclaration": 10
},
"id": 13,
"name": "IdentifierPath",
"src": "117:1:1"
}
],
"id": 14,
"name": "InheritanceSpecifier",
"src": "117:1:1"
},
{
"attributes":
{
"baseFunctions":
[
4,
9
],
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 22,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"children":
[
{
"attributes":
{
"name": "A",
"referencedDeclaration": 5
},
"id": 16,
"name": "IdentifierPath",
"src": "154:1:1"
},
{
"attributes":
{
"name": "B",
"referencedDeclaration": 10
},
"id": 17,
"name": "IdentifierPath",
"src": "157:1:1"
}
],
"id": 18,
"name": "OverrideSpecifier",
"src": "145:14:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 15,
"name": "ParameterList",
"src": "135:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 19,
"name": "ParameterList",
"src": "160:0:1"
},
{
"attributes":
{
"statements":
[
null
]
},
"children": [],
"id": 20,
"name": "Block",
"src": "160:2:1"
}
],
"id": 21,
"name": "FunctionDefinition",
"src": "125:37:1"
}
],
"id": 22,
"name": "ContractDefinition",
"src": "100:64:1"
}
],
"id": 23,
"name": "SourceUnit",
"src": "0:165:1"
}

View File

@ -1,165 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
9
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
9
],
"name": "C",
"scope": 10
},
"children":
[
{
"attributes":
{
"functionSelector": "26121ff0",
"implemented": true,
"isConstructor": false,
"kind": "function",
"modifiers":
[
null
],
"name": "f",
"scope": 9,
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
"children":
[
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 1,
"name": "ParameterList",
"src": "23:2:1"
},
{
"attributes":
{
"parameters":
[
null
]
},
"children": [],
"id": 2,
"name": "ParameterList",
"src": "33:0:1"
},
{
"children":
[
{
"attributes":
{
"assignments":
[
4
]
},
"children":
[
{
"attributes":
{
"constant": false,
"mutability": "mutable",
"name": "x",
"scope": 7,
"stateVariable": false,
"storageLocation": "memory",
"type": "string",
"visibility": "internal"
},
"children":
[
{
"attributes":
{
"name": "string",
"type": "string"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "35:6:1"
}
],
"id": 4,
"name": "VariableDeclaration",
"src": "35:15:1"
},
{
"attributes":
{
"hexvalue": "48656c6c6f20f09f9883",
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"token": "unicodeString",
"type": "literal_string hex\"48656c6c6f20f09f9883\"",
"value": "Hello \ud83d\ude03"
},
"id": 5,
"name": "Literal",
"src": "53:19:1"
}
],
"id": 6,
"name": "VariableDeclarationStatement",
"src": "35:37:1"
}
],
"id": 7,
"name": "Block",
"src": "33:42:1"
}
],
"id": 8,
"name": "FunctionDefinition",
"src": "13:62:1"
}
],
"id": 9,
"name": "ContractDefinition",
"src": "0:77:1"
}
],
"id": 10,
"name": "SourceUnit",
"src": "0:78:1"
}

View File

@ -1,108 +0,0 @@
{
"attributes":
{
"absolutePath": "a",
"exportedSymbols":
{
"C":
[
5
],
"L":
[
1
]
}
},
"children":
[
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "library",
"fullyImplemented": true,
"linearizedBaseContracts":
[
1
],
"name": "L",
"nodes":
[
null
],
"scope": 6
},
"id": 1,
"name": "ContractDefinition",
"src": "0:12:1"
},
{
"attributes":
{
"abstract": false,
"baseContracts":
[
null
],
"contractDependencies":
[
null
],
"contractKind": "contract",
"fullyImplemented": true,
"linearizedBaseContracts":
[
5
],
"name": "C",
"scope": 6
},
"children":
[
{
"children":
[
{
"attributes":
{
"name": "L",
"referencedDeclaration": 1
},
"id": 2,
"name": "IdentifierPath",
"src": "32:1:1"
},
{
"attributes":
{
"name": "uint",
"type": "uint256"
},
"id": 3,
"name": "ElementaryTypeName",
"src": "38:4:1"
}
],
"id": 4,
"name": "UsingForDirective",
"src": "26:17:1"
}
],
"id": 5,
"name": "ContractDefinition",
"src": "13:32:1"
}
],
"id": 6,
"name": "SourceUnit",
"src": "0:46:1"
}

View File

@ -74,7 +74,6 @@ ASTJSONTest::ASTJSONTest(string const& _filename)
m_astFilename = _filename.substr(0, _filename.size() - 4) + ".json";
m_astParseOnlyFilename = _filename.substr(0, _filename.size() - 4) + "_parseOnly.json";
m_legacyAstFilename = _filename.substr(0, _filename.size() - 4) + "_legacy.json";
ifstream file(_filename);
if (!file)
@ -123,14 +122,6 @@ ASTJSONTest::ASTJSONTest(string const& _filename)
}
file.close();
file.open(m_legacyAstFilename);
if (file)
{
string line;
while (getline(file, line))
m_expectationLegacy += line + "\n";
}
file.close();
}
TestCase::TestResult ASTJSONTest::run(ostream& _stream, string const& _linePrefix, bool const _formatted)
@ -161,7 +152,6 @@ TestCase::TestResult ASTJSONTest::run(ostream& _stream, string const& _linePrefi
m_resultParseOnly,
sourceIndices,
c,
false,
"parseOnly",
_stream,
_linePrefix,
@ -174,7 +164,7 @@ TestCase::TestResult ASTJSONTest::run(ostream& _stream, string const& _linePrefi
if (!c.parse())
{
// Empty Expectations means we expect failure
if (m_expectation.empty() && m_expectationLegacy.empty())
if (m_expectation.empty())
return resultsMatch ? TestResult::Success : TestResult::Failure;
SourceReferenceFormatterHuman formatter(_stream, _formatted, false);
@ -190,25 +180,12 @@ TestCase::TestResult ASTJSONTest::run(ostream& _stream, string const& _linePrefi
m_result,
sourceIndices,
c,
false,
"",
_stream,
_linePrefix,
_formatted
) && resultsMatch;
resultsMatch = runTest(
m_expectationLegacy,
m_resultLegacy,
sourceIndices,
c,
true,
"legacy",
_stream,
_linePrefix,
_formatted
) && resultsMatch;
return resultsMatch ? TestResult::Success : TestResult::Failure;
}
@ -217,7 +194,6 @@ bool ASTJSONTest::runTest(
string& _result,
map<string, unsigned> const& _sourceIndices,
CompilerStack& _compiler,
bool _legacy,
string const& _variation,
ostream& _stream,
string const& _linePrefix,
@ -230,7 +206,7 @@ bool ASTJSONTest::runTest(
for (size_t i = 0; i < m_sources.size(); i++)
{
ostringstream result;
ASTJsonConverter(_legacy, _compiler.state(), _sourceIndices).print(result, _compiler.ast(m_sources[i].first));
ASTJsonConverter(_compiler.state(), _sourceIndices).print(result, _compiler.ast(m_sources[i].first));
_result += result.str();
if (i != m_sources.size() - 1)
_result += ",";
@ -293,7 +269,6 @@ void ASTJSONTest::printSource(ostream& _stream, string const& _linePrefix, bool
void ASTJSONTest::printUpdatedExpectations(std::ostream&, std::string const&) const
{
updateExpectation(m_astFilename, m_result, "");
updateExpectation(m_legacyAstFilename, m_resultLegacy, "legacy ");
updateExpectation(m_astParseOnlyFilename, m_resultParseOnly, "parseOnly ");
}

View File

@ -38,7 +38,9 @@ class ASTJSONTest: public TestCase
{
public:
static std::unique_ptr<TestCase> create(Config const& _config)
{ return std::make_unique<ASTJSONTest>(_config.filename); }
{
return std::make_unique<ASTJSONTest>(_config.filename);
}
ASTJSONTest(std::string const& _filename);
TestResult run(std::ostream& _stream, std::string const& _linePrefix = "", bool const _formatted = false) override;
@ -51,7 +53,6 @@ private:
std::string& _result,
std::map<std::string, unsigned> const& _sourceIndices,
CompilerStack& _compiler,
bool _parseOnly,
std::string const& _variation,
std::ostream& _stream,
std::string const& _linePrefix = "",
@ -64,12 +65,10 @@ private:
) const;
std::vector<std::pair<std::string, std::string>> m_sources;
std::string m_expectationLegacy;
std::string m_expectationParseOnly;
std::string m_astFilename;
std::string m_astParseOnlyFilename;
std::string m_result;
std::string m_resultLegacy;
std::string m_resultParseOnly;
};

View File

@ -385,7 +385,7 @@ BOOST_AUTO_TEST_CASE(basic_compilation)
"outputSelection": {
"fileA": {
"A": [ "abi", "devdoc", "userdoc", "evm.bytecode", "evm.assembly", "evm.gasEstimates", "evm.legacyAssembly", "metadata" ],
"": [ "legacyAST" ]
"": [ "ast" ]
}
}
}
@ -468,13 +468,13 @@ BOOST_AUTO_TEST_CASE(basic_compilation)
BOOST_CHECK(solidity::test::isValidMetadata(contract["metadata"].asString()));
BOOST_CHECK(result["sources"].isObject());
BOOST_CHECK(result["sources"]["fileA"].isObject());
BOOST_CHECK(result["sources"]["fileA"]["legacyAST"].isObject());
BOOST_CHECK(result["sources"]["fileA"]["ast"].isObject());
BOOST_CHECK_EQUAL(
util::jsonCompactPrint(result["sources"]["fileA"]["legacyAST"]),
"{\"attributes\":{\"absolutePath\":\"fileA\",\"exportedSymbols\":{\"A\":[1]}},\"children\":"
"[{\"attributes\":{\"abstract\":false,\"baseContracts\":[null],\"contractDependencies\":[null],\"contractKind\":\"contract\","
"\"fullyImplemented\":true,\"linearizedBaseContracts\":[1],\"name\":\"A\",\"nodes\":[null],\"scope\":2},"
"\"id\":1,\"name\":\"ContractDefinition\",\"src\":\"0:14:0\"}],\"id\":2,\"name\":\"SourceUnit\",\"src\":\"0:14:0\"}"
util::jsonCompactPrint(result["sources"]["fileA"]["ast"]),
"{\"absolutePath\":\"fileA\",\"exportedSymbols\":{\"A\":[1]},\"id\":2,\"nodeType\":\"SourceUnit\",\"nodes\":[{\"abstract\":false,"
"\"baseContracts\":[],\"contractDependencies\":[],\"contractKind\":\"contract\",\"fullyImplemented\":true,\"id\":1,"
"\"linearizedBaseContracts\":[1],\"name\":\"A\",\"nodeType\":\"ContractDefinition\",\"nodes\":[],\"scope\":2,"
"\"src\":\"0:14:0\"}],\"src\":\"0:14:0\"}"
);
}