UNPKG

@netvote/elections-solidity

Version:
1,225 lines 125 kB
{ "contractName": "Bytes32Set", "abi": [ { "constant": true, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" } ], "name": "size", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" }, { "name": "index", "type": "uint256" } ], "name": "getAt", "outputs": [ { "name": "", "type": "bytes32" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" }, { "name": "b", "type": "bytes32" } ], "name": "contains", "outputs": [ { "name": "", "type": "bool" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" }, { "name": "b", "type": "bytes32" } ], "name": "remove", "outputs": [], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" }, { "name": "b", "type": "bytes32" } ], "name": "indexOf", "outputs": [ { "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "name": "self", "type": "Bytes32Set.SetData storage" }, { "name": "b", "type": "bytes32" } ], "name": "put", "outputs": [], "payable": false, "stateMutability": "nonpayable", "type": "function" } ], "bytecode": "0x6060604052341561000f57600080fd5b61031c8061001e6000396000f3006060604052600436106100775763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166336406111811461007c5780639286e54114610099578063932dd839146100a75780639e3084b0146100c9578063c4614893146100d9578063fffd9592146100e7575b600080fd5b6100876004356100f5565b60405190815260200160405180910390f35b6100876004356024356100fc565b6100b5600435602435610123565b604051901515815260200160405180910390f35b6100d7600435602435610139565b005b610087600435602435610215565b6100d760043560243561022b565b6002015490565b6000826002018281548110151561010f57fe5b906000526020600020900154905092915050565b6000908152602091909152604090205460ff1690565b600081815260208390526040812054819060ff161561020f57600083815260018086016020526040909120549250610170856100f5565b038210156101d757836002016001610187866100f5565b0381548110151561019457fe5b90600052602060002090015490508084600201838154811015156101b457fe5b600091825260208083209091019290925582815260018601909152604090208290555b600284018054906101ec9060001983016102a6565b50600083815260208581526040808320805460ff19169055600187019091528120555b50505050565b6000908152600191909101602052604090205490565b60008181526020839052604090205460ff1615156102a2576000818152602083905260409020805460ff191660019081179091556002830180549091810161027383826102a6565b506000918252602080832091909101839055600284015483835260018501909152604090912060001990910190555b5050565b8154818355818115116102ca576000838152602090206102ca9181019083016102cf565b505050565b6102ed91905b808211156102e957600081556001016102d5565b5090565b905600a165627a7a723058209c07b5862213c958581043a31f5e4b8ea5c1643476478f95079beea7679bc0770029", "deployedBytecode": "0x6060604052600436106100775763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166336406111811461007c5780639286e54114610099578063932dd839146100a75780639e3084b0146100c9578063c4614893146100d9578063fffd9592146100e7575b600080fd5b6100876004356100f5565b60405190815260200160405180910390f35b6100876004356024356100fc565b6100b5600435602435610123565b604051901515815260200160405180910390f35b6100d7600435602435610139565b005b610087600435602435610215565b6100d760043560243561022b565b6002015490565b6000826002018281548110151561010f57fe5b906000526020600020900154905092915050565b6000908152602091909152604090205460ff1690565b600081815260208390526040812054819060ff161561020f57600083815260018086016020526040909120549250610170856100f5565b038210156101d757836002016001610187866100f5565b0381548110151561019457fe5b90600052602060002090015490508084600201838154811015156101b457fe5b600091825260208083209091019290925582815260018601909152604090208290555b600284018054906101ec9060001983016102a6565b50600083815260208581526040808320805460ff19169055600187019091528120555b50505050565b6000908152600191909101602052604090205490565b60008181526020839052604090205460ff1615156102a2576000818152602083905260409020805460ff191660019081179091556002830180549091810161027383826102a6565b506000918252602080832091909101839055600284015483835260018501909152604090912060001990910190555b5050565b8154818355818115116102ca576000838152602090206102ca9181019083016102cf565b505050565b6102ed91905b808211156102e957600081556001016102d5565b5090565b905600a165627a7a723058209c07b5862213c958581043a31f5e4b8ea5c1643476478f95079beea7679bc0770029", "sourceMap": "1037:1521:13:-;;;;;;;;;;;;;;;;;", "deployedSourceMap": "1037:1521:13:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1610:113;;;;;;;;;;;;;;;;;;;;;1344:129;;;;;;;;1479:125;;;;;;;;;;;;;;;;;;;;;;;;;1973:583;;;;;;;;;;1212:126;;;;;;;;1729:238;;;;;;;;1610:113;1697:12;;:19;;1610:113::o;1344:129::-;1421:7;1447:4;:12;;1460:5;1447:19;;;;;;;;;;;;;;;;;;;1440:26;;1344:129;;;;:::o;1479:125::-;1555:4;1578:19;;;;;;;;;;;;;;;1479:125::o;1973:583::-;2078:13;2043:19;;;;;;;;;;;2078:13;;2043:19;;2039:511;;;2094:18;;;;:15;;;;:18;;;;;;;;-1:-1:-1;2202:10:13;2094:4;2202;:10::i;:::-;:14;2194:5;:22;2190:208;;;2256:4;:12;;2280:1;2269:10;2274:4;2269;:10::i;:::-;:12;2256:26;;;;;;;;;;;;;;;;;;;2236:46;;2322:9;2300:4;:12;;2313:5;2300:19;;;;;;;;;;;;;;;;;;;;;:31;;;;2349:26;;;:15;;;:26;;;;;;:34;;;2190:208;2439:12;;;:21;;;;;-1:-1:-1;;2439:21:13;;;:::i;:::-;-1:-1:-1;2481:16:13;:19;;;;;;;;;;;2474:26;;-1:-1:-1;;2474:26:13;;;;2521:15;;:18;;;;;2514:25;2039:511;1973:583;;;;:::o;1212:126::-;1287:7;1313:18;;;:15;;;;;:18;;;;;;;1212:126::o;1729:238::-;1797:16;:19;;;;;;;;;;;;;1796:20;1792:169;;;1832:16;:19;;;;;;;;;;:26;;-1:-1:-1;;1832:26:13;1854:4;1832:26;;;;;;1872:12;;;:20;;:12;;:20;;;:12;:20;;:::i;:::-;-1:-1:-1;1872:20:13;;;;;;;;;;;;;;;1927:12;;;:19;1906:18;;;1949:1;1906:15;;:18;;;;;;;-1:-1:-1;;1927:23:13;;;1906:44;;1792:169;1729:238;;:::o;1037:1521::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;:::o", "source": "// ------------------------------------------------------------------------------\n// This file is part of netvote.\n//\n// netvote is free software: you can redistribute it and/or modify\n// it under the terms of the GNU General Public License as published by\n// the Free Software Foundation, either version 3 of the License, or\n// (at your option) any later version.\n//\n// netvote is distributed in the hope that it will be useful,\n// but WITHOUT ANY WARRANTY; without even the implied warranty of\n// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n// GNU General Public License for more details.\n//\n// You should have received a copy of the GNU General Public License\n// along with solidity. If not, see <http://www.gnu.org/licenses/>\n//\n// (c) 2017 netvote contributors.\n//------------------------------------------------------------------------------\n\npragma solidity ^0.4.17;\n\n\n/**\n * @title Bytes32Set\n * @dev iterable map of bytes32 for that modifies size upon removal\n * Note that the order changes upon removal.\n */\nlibrary Bytes32Set {\n\n struct SetData {\n mapping(bytes32 => bool) entryExists;\n mapping(bytes32 => uint256) entryIndex;\n bytes32[] entries;\n }\n\n function indexOf(SetData storage self, bytes32 b) public constant returns (uint256) {\n return self.entryIndex[b];\n }\n\n function getAt(SetData storage self, uint256 index) public constant returns (bytes32) {\n return self.entries[index];\n }\n\n function contains(SetData storage self, bytes32 b) public constant returns (bool) {\n return self.entryExists[b];\n }\n\n function size(SetData storage self) public constant returns (uint256) {\n return self.entries.length;\n }\n\n function put(SetData storage self, bytes32 b) public {\n if (!self.entryExists[b]) {\n self.entryExists[b] = true;\n self.entries.push(b);\n self.entryIndex[b] = self.entries.length - 1;\n }\n }\n\n function remove(SetData storage self, bytes32 b) public {\n if (self.entryExists[b]) {\n uint256 index = self.entryIndex[b];\n // if not last entry, copy last entry into b's slot\n if (index < size(self) - 1) {\n bytes32 lastEntry = self.entries[size(self)-1];\n self.entries[index] = lastEntry;\n self.entryIndex[lastEntry] = index;\n }\n // resize array\n self.entries.length--;\n delete self.entryExists[b];\n delete self.entryIndex[b];\n }\n }\n}", "sourcePath": "/Users/slanders/netvote/elections-solidity/contracts/lib/Bytes32Set.sol", "ast": { "attributes": { "absolutePath": "/Users/slanders/netvote/elections-solidity/contracts/lib/Bytes32Set.sol", "exportedSymbols": { "Bytes32Set": [ 1924 ] } }, "children": [ { "attributes": { "literals": [ "solidity", "^", "0.4", ".17" ] }, "id": 1735, "name": "PragmaDirective", "src": "868:24:13" }, { "attributes": { "baseContracts": [ null ], "contractDependencies": [ null ], "contractKind": "library", "documentation": "@title Bytes32Set\n@dev iterable map of bytes32 for that modifies size upon removal\nNote that the order changes upon removal.", "fullyImplemented": true, "linearizedBaseContracts": [ 1924 ], "name": "Bytes32Set", "scope": 1925 }, "children": [ { "attributes": { "canonicalName": "Bytes32Set.SetData", "name": "SetData", "scope": 1924, "visibility": "public" }, "children": [ { "attributes": { "constant": false, "name": "entryExists", "scope": 1747, "stateVariable": false, "storageLocation": "default", "type": "mapping(bytes32 => bool)", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "type": "mapping(bytes32 => bool)" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1736, "name": "ElementaryTypeName", "src": "1096:7:13" }, { "attributes": { "name": "bool", "type": "bool" }, "id": 1737, "name": "ElementaryTypeName", "src": "1107:4:13" } ], "id": 1738, "name": "Mapping", "src": "1088:24:13" } ], "id": 1739, "name": "VariableDeclaration", "src": "1088:36:13" }, { "attributes": { "constant": false, "name": "entryIndex", "scope": 1747, "stateVariable": false, "storageLocation": "default", "type": "mapping(bytes32 => uint256)", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "type": "mapping(bytes32 => uint256)" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1740, "name": "ElementaryTypeName", "src": "1142:7:13" }, { "attributes": { "name": "uint256", "type": "uint256" }, "id": 1741, "name": "ElementaryTypeName", "src": "1153:7:13" } ], "id": 1742, "name": "Mapping", "src": "1134:27:13" } ], "id": 1743, "name": "VariableDeclaration", "src": "1134:38:13" }, { "attributes": { "constant": false, "name": "entries", "scope": 1747, "stateVariable": false, "storageLocation": "default", "type": "bytes32[] storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "length": null, "type": "bytes32[] storage pointer" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1744, "name": "ElementaryTypeName", "src": "1182:7:13" } ], "id": 1745, "name": "ArrayTypeName", "src": "1182:9:13" } ], "id": 1746, "name": "VariableDeclaration", "src": "1182:17:13" } ], "id": 1747, "name": "StructDefinition", "src": "1063:143:13" }, { "attributes": { "constant": true, "implemented": true, "isConstructor": false, "modifiers": [ null ], "name": "indexOf", "payable": false, "scope": 1924, "stateMutability": "view", "superFunction": null, "visibility": "public" }, "children": [ { "children": [ { "attributes": { "constant": false, "name": "self", "scope": 1762, "stateVariable": false, "storageLocation": "storage", "type": "struct Bytes32Set.SetData storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "contractScope": null, "name": "SetData", "referencedDeclaration": 1747, "type": "struct Bytes32Set.SetData storage pointer" }, "id": 1748, "name": "UserDefinedTypeName", "src": "1229:7:13" } ], "id": 1749, "name": "VariableDeclaration", "src": "1229:20:13" }, { "attributes": { "constant": false, "name": "b", "scope": 1762, "stateVariable": false, "storageLocation": "default", "type": "bytes32", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1750, "name": "ElementaryTypeName", "src": "1251:7:13" } ], "id": 1751, "name": "VariableDeclaration", "src": "1251:9:13" } ], "id": 1752, "name": "ParameterList", "src": "1228:33:13" }, { "children": [ { "attributes": { "constant": false, "name": "", "scope": 1762, "stateVariable": false, "storageLocation": "default", "type": "uint256", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "uint256", "type": "uint256" }, "id": 1753, "name": "ElementaryTypeName", "src": "1287:7:13" } ], "id": 1754, "name": "VariableDeclaration", "src": "1287:7:13" } ], "id": 1755, "name": "ParameterList", "src": "1286:9:13" }, { "children": [ { "attributes": { "functionReturnParameters": 1755 }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "type": "uint256" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "entryIndex", "referencedDeclaration": 1743, "type": "mapping(bytes32 => uint256)" }, "children": [ { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1749, "type": "struct Bytes32Set.SetData storage pointer", "value": "self" }, "id": 1756, "name": "Identifier", "src": "1313:4:13" } ], "id": 1757, "name": "MemberAccess", "src": "1313:15:13" }, { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1751, "type": "bytes32", "value": "b" }, "id": 1758, "name": "Identifier", "src": "1329:1:13" } ], "id": 1759, "name": "IndexAccess", "src": "1313:18:13" } ], "id": 1760, "name": "Return", "src": "1306:25:13" } ], "id": 1761, "name": "Block", "src": "1296:42:13" } ], "id": 1762, "name": "FunctionDefinition", "src": "1212:126:13" }, { "attributes": { "constant": true, "implemented": true, "isConstructor": false, "modifiers": [ null ], "name": "getAt", "payable": false, "scope": 1924, "stateMutability": "view", "superFunction": null, "visibility": "public" }, "children": [ { "children": [ { "attributes": { "constant": false, "name": "self", "scope": 1777, "stateVariable": false, "storageLocation": "storage", "type": "struct Bytes32Set.SetData storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "contractScope": null, "name": "SetData", "referencedDeclaration": 1747, "type": "struct Bytes32Set.SetData storage pointer" }, "id": 1763, "name": "UserDefinedTypeName", "src": "1359:7:13" } ], "id": 1764, "name": "VariableDeclaration", "src": "1359:20:13" }, { "attributes": { "constant": false, "name": "index", "scope": 1777, "stateVariable": false, "storageLocation": "default", "type": "uint256", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "uint256", "type": "uint256" }, "id": 1765, "name": "ElementaryTypeName", "src": "1381:7:13" } ], "id": 1766, "name": "VariableDeclaration", "src": "1381:13:13" } ], "id": 1767, "name": "ParameterList", "src": "1358:37:13" }, { "children": [ { "attributes": { "constant": false, "name": "", "scope": 1777, "stateVariable": false, "storageLocation": "default", "type": "bytes32", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1768, "name": "ElementaryTypeName", "src": "1421:7:13" } ], "id": 1769, "name": "VariableDeclaration", "src": "1421:7:13" } ], "id": 1770, "name": "ParameterList", "src": "1420:9:13" }, { "children": [ { "attributes": { "functionReturnParameters": 1770 }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "type": "bytes32" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "entries", "referencedDeclaration": 1746, "type": "bytes32[] storage ref" }, "children": [ { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1764, "type": "struct Bytes32Set.SetData storage pointer", "value": "self" }, "id": 1771, "name": "Identifier", "src": "1447:4:13" } ], "id": 1772, "name": "MemberAccess", "src": "1447:12:13" }, { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1766, "type": "uint256", "value": "index" }, "id": 1773, "name": "Identifier", "src": "1460:5:13" } ], "id": 1774, "name": "IndexAccess", "src": "1447:19:13" } ], "id": 1775, "name": "Return", "src": "1440:26:13" } ], "id": 1776, "name": "Block", "src": "1430:43:13" } ], "id": 1777, "name": "FunctionDefinition", "src": "1344:129:13" }, { "attributes": { "constant": true, "implemented": true, "isConstructor": false, "modifiers": [ null ], "name": "contains", "payable": false, "scope": 1924, "stateMutability": "view", "superFunction": null, "visibility": "public" }, "children": [ { "children": [ { "attributes": { "constant": false, "name": "self", "scope": 1792, "stateVariable": false, "storageLocation": "storage", "type": "struct Bytes32Set.SetData storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "contractScope": null, "name": "SetData", "referencedDeclaration": 1747, "type": "struct Bytes32Set.SetData storage pointer" }, "id": 1778, "name": "UserDefinedTypeName", "src": "1497:7:13" } ], "id": 1779, "name": "VariableDeclaration", "src": "1497:20:13" }, { "attributes": { "constant": false, "name": "b", "scope": 1792, "stateVariable": false, "storageLocation": "default", "type": "bytes32", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1780, "name": "ElementaryTypeName", "src": "1519:7:13" } ], "id": 1781, "name": "VariableDeclaration", "src": "1519:9:13" } ], "id": 1782, "name": "ParameterList", "src": "1496:33:13" }, { "children": [ { "attributes": { "constant": false, "name": "", "scope": 1792, "stateVariable": false, "storageLocation": "default", "type": "bool", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "bool", "type": "bool" }, "id": 1783, "name": "ElementaryTypeName", "src": "1555:4:13" } ], "id": 1784, "name": "VariableDeclaration", "src": "1555:4:13" } ], "id": 1785, "name": "ParameterList", "src": "1554:6:13" }, { "children": [ { "attributes": { "functionReturnParameters": 1785 }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "type": "bool" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "entryExists", "referencedDeclaration": 1739, "type": "mapping(bytes32 => bool)" }, "children": [ { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1779, "type": "struct Bytes32Set.SetData storage pointer", "value": "self" }, "id": 1786, "name": "Identifier", "src": "1578:4:13" } ], "id": 1787, "name": "MemberAccess", "src": "1578:16:13" }, { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1781, "type": "bytes32", "value": "b" }, "id": 1788, "name": "Identifier", "src": "1595:1:13" } ], "id": 1789, "name": "IndexAccess", "src": "1578:19:13" } ], "id": 1790, "name": "Return", "src": "1571:26:13" } ], "id": 1791, "name": "Block", "src": "1561:43:13" } ], "id": 1792, "name": "FunctionDefinition", "src": "1479:125:13" }, { "attributes": { "constant": true, "implemented": true, "isConstructor": false, "modifiers": [ null ], "name": "size", "payable": false, "scope": 1924, "stateMutability": "view", "superFunction": null, "visibility": "public" }, "children": [ { "children": [ { "attributes": { "constant": false, "name": "self", "scope": 1804, "stateVariable": false, "storageLocation": "storage", "type": "struct Bytes32Set.SetData storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "contractScope": null, "name": "SetData", "referencedDeclaration": 1747, "type": "struct Bytes32Set.SetData storage pointer" }, "id": 1793, "name": "UserDefinedTypeName", "src": "1624:7:13" } ], "id": 1794, "name": "VariableDeclaration", "src": "1624:20:13" } ], "id": 1795, "name": "ParameterList", "src": "1623:22:13" }, { "children": [ { "attributes": { "constant": false, "name": "", "scope": 1804, "stateVariable": false, "storageLocation": "default", "type": "uint256", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "uint256", "type": "uint256" }, "id": 1796, "name": "ElementaryTypeName", "src": "1671:7:13" } ], "id": 1797, "name": "VariableDeclaration", "src": "1671:7:13" } ], "id": 1798, "name": "ParameterList", "src": "1670:9:13" }, { "children": [ { "attributes": { "functionReturnParameters": 1798 }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "length", "referencedDeclaration": null, "type": "uint256" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "entries", "referencedDeclaration": 1746, "type": "bytes32[] storage ref" }, "children": [ { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1794, "type": "struct Bytes32Set.SetData storage pointer", "value": "self" }, "id": 1799, "name": "Identifier", "src": "1697:4:13" } ], "id": 1800, "name": "MemberAccess", "src": "1697:12:13" } ], "id": 1801, "name": "MemberAccess", "src": "1697:19:13" } ], "id": 1802, "name": "Return", "src": "1690:26:13" } ], "id": 1803, "name": "Block", "src": "1680:43:13" } ], "id": 1804, "name": "FunctionDefinition", "src": "1610:113:13" }, { "attributes": { "constant": false, "implemented": true, "isConstructor": false, "modifiers": [ null ], "name": "put", "payable": false, "scope": 1924, "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, "children": [ { "children": [ { "attributes": { "constant": false, "name": "self", "scope": 1847, "stateVariable": false, "storageLocation": "storage", "type": "struct Bytes32Set.SetData storage pointer", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "contractScope": null, "name": "SetData", "referencedDeclaration": 1747, "type": "struct Bytes32Set.SetData storage pointer" }, "id": 1805, "name": "UserDefinedTypeName", "src": "1742:7:13" } ], "id": 1806, "name": "VariableDeclaration", "src": "1742:20:13" }, { "attributes": { "constant": false, "name": "b", "scope": 1847, "stateVariable": false, "storageLocation": "default", "type": "bytes32", "value": null, "visibility": "internal" }, "children": [ { "attributes": { "name": "bytes32", "type": "bytes32" }, "id": 1807, "name": "ElementaryTypeName", "src": "1764:7:13" } ], "id": 1808, "name": "VariableDeclaration", "src": "1764:9:13" } ], "id": 1809, "name": "ParameterList", "src": "1741:33:13" }, { "attributes": { "parameters": [ null ] }, "children": [], "id": 1810, "name": "ParameterList", "src": "1782:0:13" }, { "children": [ { "attributes": { "falseBody": null }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "operator": "!", "prefix": true, "type": "bool" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "type": "bool" }, "children": [ { "attributes": { "argumentTypes": null, "isConstant": false, "isLValue": true, "isPure": false, "lValueRequested": false, "member_name": "entryExists", "referencedDeclaration": 1739, "type": "mapping(bytes32 => bool)" }, "children": [ { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1806, "type": "struct Bytes32Set.SetData storage pointer", "value": "self" }, "id": 1811, "name": "Identifier", "src": "1797:4:13" } ], "id": 1812, "name": "MemberAccess", "src": "1797:16:13" }, { "attributes": { "argumentTypes": null, "overloadedDeclarations": [ null ], "referencedDeclaration": 1808, "type": "bytes32", "value": "b" }, "id": 1813, "name": "Identifier", "src": "1814:1:13" } ], "id": 1814, "name": "IndexAccess", "src": "1797:19:13" } ], "id": 1815, "name": "UnaryOperation", "src": "1796:20:13" }, { "children": [ { "children": [ { "attributes": { "argumentTypes": null, "i