@etherisc/registry-contracts
Version:
Etherisc's smart contracts for the registry.
943 lines • 36.6 kB
JSON
{
"abi": [],
"allSourcePaths": {
"24": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/StorageSlot.sol"
},
"ast": {
"absolutePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/StorageSlot.sol",
"exportedSymbols": {
"StorageSlot": [
18446
]
},
"id": 18447,
"license": "MIT",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 18388,
"literals": [
"solidity",
"^",
"0.8",
".0"
],
"nodeType": "PragmaDirective",
"src": "105:23:24"
},
{
"abstract": false,
"baseContracts": [],
"canonicalName": "StorageSlot",
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 18389,
"nodeType": "StructuredDocumentation",
"src": "130:1148:24",
"text": " @dev Library for reading and writing primitive types to specific storage slots.\n Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\n This library helps with reading and writing to such slots without the need for inline assembly.\n The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\n Example usage to set ERC1967 implementation slot:\n ```\n contract ERC1967 {\n bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n function _getImplementation() internal view returns (address) {\n return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\n }\n function _setImplementation(address newImplementation) internal {\n require(Address.isContract(newImplementation), \"ERC1967: new implementation is not a contract\");\n StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\n }\n }\n ```\n _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._"
},
"fullyImplemented": true,
"id": 18446,
"linearizedBaseContracts": [
18446
],
"name": "StorageSlot",
"nameLocation": "1287:11:24",
"nodeType": "ContractDefinition",
"nodes": [
{
"canonicalName": "StorageSlot.AddressSlot",
"id": 18392,
"members": [
{
"constant": false,
"id": 18391,
"mutability": "mutable",
"name": "value",
"nameLocation": "1342:5:24",
"nodeType": "VariableDeclaration",
"scope": 18392,
"src": "1334:13:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 18390,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1334:7:24",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"visibility": "internal"
}
],
"name": "AddressSlot",
"nameLocation": "1312:11:24",
"nodeType": "StructDefinition",
"scope": 18446,
"src": "1305:49:24",
"visibility": "public"
},
{
"canonicalName": "StorageSlot.BooleanSlot",
"id": 18395,
"members": [
{
"constant": false,
"id": 18394,
"mutability": "mutable",
"name": "value",
"nameLocation": "1394:5:24",
"nodeType": "VariableDeclaration",
"scope": 18395,
"src": "1389:10:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 18393,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1389:4:24",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"visibility": "internal"
}
],
"name": "BooleanSlot",
"nameLocation": "1367:11:24",
"nodeType": "StructDefinition",
"scope": 18446,
"src": "1360:46:24",
"visibility": "public"
},
{
"canonicalName": "StorageSlot.Bytes32Slot",
"id": 18398,
"members": [
{
"constant": false,
"id": 18397,
"mutability": "mutable",
"name": "value",
"nameLocation": "1449:5:24",
"nodeType": "VariableDeclaration",
"scope": 18398,
"src": "1441:13:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 18396,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "1441:7:24",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"name": "Bytes32Slot",
"nameLocation": "1419:11:24",
"nodeType": "StructDefinition",
"scope": 18446,
"src": "1412:49:24",
"visibility": "public"
},
{
"canonicalName": "StorageSlot.Uint256Slot",
"id": 18401,
"members": [
{
"constant": false,
"id": 18400,
"mutability": "mutable",
"name": "value",
"nameLocation": "1504:5:24",
"nodeType": "VariableDeclaration",
"scope": 18401,
"src": "1496:13:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 18399,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1496:7:24",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"visibility": "internal"
}
],
"name": "Uint256Slot",
"nameLocation": "1474:11:24",
"nodeType": "StructDefinition",
"scope": 18446,
"src": "1467:49:24",
"visibility": "public"
},
{
"body": {
"id": 18411,
"nodeType": "Block",
"src": "1698:106:24",
"statements": [
{
"AST": {
"nodeType": "YulBlock",
"src": "1760:38:24",
"statements": [
{
"nodeType": "YulAssignment",
"src": "1774:14:24",
"value": {
"name": "slot",
"nodeType": "YulIdentifier",
"src": "1784:4:24"
},
"variableNames": [
{
"name": "r.slot",
"nodeType": "YulIdentifier",
"src": "1774:6:24"
}
]
}
]
},
"documentation": "@solidity memory-safe-assembly",
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 18408,
"isOffset": false,
"isSlot": true,
"src": "1774:6:24",
"suffix": "slot",
"valueSize": 1
},
{
"declaration": 18404,
"isOffset": false,
"isSlot": false,
"src": "1784:4:24",
"valueSize": 1
}
],
"id": 18410,
"nodeType": "InlineAssembly",
"src": "1751:47:24"
}
]
},
"documentation": {
"id": 18402,
"nodeType": "StructuredDocumentation",
"src": "1522:87:24",
"text": " @dev Returns an `AddressSlot` with member `value` located at `slot`."
},
"id": 18412,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "getAddressSlot",
"nameLocation": "1623:14:24",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 18405,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18404,
"mutability": "mutable",
"name": "slot",
"nameLocation": "1646:4:24",
"nodeType": "VariableDeclaration",
"scope": 18412,
"src": "1638:12:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 18403,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "1638:7:24",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "1637:14:24"
},
"returnParameters": {
"id": 18409,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18408,
"mutability": "mutable",
"name": "r",
"nameLocation": "1695:1:24",
"nodeType": "VariableDeclaration",
"scope": 18412,
"src": "1675:21:24",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_AddressSlot_$18392_storage_ptr",
"typeString": "struct StorageSlot.AddressSlot"
},
"typeName": {
"id": 18407,
"nodeType": "UserDefinedTypeName",
"pathNode": {
"id": 18406,
"name": "AddressSlot",
"nameLocations": [
"1675:11:24"
],
"nodeType": "IdentifierPath",
"referencedDeclaration": 18392,
"src": "1675:11:24"
},
"referencedDeclaration": 18392,
"src": "1675:11:24",
"typeDescriptions": {
"typeIdentifier": "t_struct$_AddressSlot_$18392_storage_ptr",
"typeString": "struct StorageSlot.AddressSlot"
}
},
"visibility": "internal"
}
],
"src": "1674:23:24"
},
"scope": 18446,
"src": "1614:190:24",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 18422,
"nodeType": "Block",
"src": "1986:106:24",
"statements": [
{
"AST": {
"nodeType": "YulBlock",
"src": "2048:38:24",
"statements": [
{
"nodeType": "YulAssignment",
"src": "2062:14:24",
"value": {
"name": "slot",
"nodeType": "YulIdentifier",
"src": "2072:4:24"
},
"variableNames": [
{
"name": "r.slot",
"nodeType": "YulIdentifier",
"src": "2062:6:24"
}
]
}
]
},
"documentation": "@solidity memory-safe-assembly",
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 18419,
"isOffset": false,
"isSlot": true,
"src": "2062:6:24",
"suffix": "slot",
"valueSize": 1
},
{
"declaration": 18415,
"isOffset": false,
"isSlot": false,
"src": "2072:4:24",
"valueSize": 1
}
],
"id": 18421,
"nodeType": "InlineAssembly",
"src": "2039:47:24"
}
]
},
"documentation": {
"id": 18413,
"nodeType": "StructuredDocumentation",
"src": "1810:87:24",
"text": " @dev Returns an `BooleanSlot` with member `value` located at `slot`."
},
"id": 18423,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "getBooleanSlot",
"nameLocation": "1911:14:24",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 18416,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18415,
"mutability": "mutable",
"name": "slot",
"nameLocation": "1934:4:24",
"nodeType": "VariableDeclaration",
"scope": 18423,
"src": "1926:12:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 18414,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "1926:7:24",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "1925:14:24"
},
"returnParameters": {
"id": 18420,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18419,
"mutability": "mutable",
"name": "r",
"nameLocation": "1983:1:24",
"nodeType": "VariableDeclaration",
"scope": 18423,
"src": "1963:21:24",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_BooleanSlot_$18395_storage_ptr",
"typeString": "struct StorageSlot.BooleanSlot"
},
"typeName": {
"id": 18418,
"nodeType": "UserDefinedTypeName",
"pathNode": {
"id": 18417,
"name": "BooleanSlot",
"nameLocations": [
"1963:11:24"
],
"nodeType": "IdentifierPath",
"referencedDeclaration": 18395,
"src": "1963:11:24"
},
"referencedDeclaration": 18395,
"src": "1963:11:24",
"typeDescriptions": {
"typeIdentifier": "t_struct$_BooleanSlot_$18395_storage_ptr",
"typeString": "struct StorageSlot.BooleanSlot"
}
},
"visibility": "internal"
}
],
"src": "1962:23:24"
},
"scope": 18446,
"src": "1902:190:24",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 18433,
"nodeType": "Block",
"src": "2274:106:24",
"statements": [
{
"AST": {
"nodeType": "YulBlock",
"src": "2336:38:24",
"statements": [
{
"nodeType": "YulAssignment",
"src": "2350:14:24",
"value": {
"name": "slot",
"nodeType": "YulIdentifier",
"src": "2360:4:24"
},
"variableNames": [
{
"name": "r.slot",
"nodeType": "YulIdentifier",
"src": "2350:6:24"
}
]
}
]
},
"documentation": "@solidity memory-safe-assembly",
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 18430,
"isOffset": false,
"isSlot": true,
"src": "2350:6:24",
"suffix": "slot",
"valueSize": 1
},
{
"declaration": 18426,
"isOffset": false,
"isSlot": false,
"src": "2360:4:24",
"valueSize": 1
}
],
"id": 18432,
"nodeType": "InlineAssembly",
"src": "2327:47:24"
}
]
},
"documentation": {
"id": 18424,
"nodeType": "StructuredDocumentation",
"src": "2098:87:24",
"text": " @dev Returns an `Bytes32Slot` with member `value` located at `slot`."
},
"id": 18434,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "getBytes32Slot",
"nameLocation": "2199:14:24",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 18427,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18426,
"mutability": "mutable",
"name": "slot",
"nameLocation": "2222:4:24",
"nodeType": "VariableDeclaration",
"scope": 18434,
"src": "2214:12:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 18425,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2214:7:24",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "2213:14:24"
},
"returnParameters": {
"id": 18431,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18430,
"mutability": "mutable",
"name": "r",
"nameLocation": "2271:1:24",
"nodeType": "VariableDeclaration",
"scope": 18434,
"src": "2251:21:24",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Bytes32Slot_$18398_storage_ptr",
"typeString": "struct StorageSlot.Bytes32Slot"
},
"typeName": {
"id": 18429,
"nodeType": "UserDefinedTypeName",
"pathNode": {
"id": 18428,
"name": "Bytes32Slot",
"nameLocations": [
"2251:11:24"
],
"nodeType": "IdentifierPath",
"referencedDeclaration": 18398,
"src": "2251:11:24"
},
"referencedDeclaration": 18398,
"src": "2251:11:24",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Bytes32Slot_$18398_storage_ptr",
"typeString": "struct StorageSlot.Bytes32Slot"
}
},
"visibility": "internal"
}
],
"src": "2250:23:24"
},
"scope": 18446,
"src": "2190:190:24",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 18444,
"nodeType": "Block",
"src": "2562:106:24",
"statements": [
{
"AST": {
"nodeType": "YulBlock",
"src": "2624:38:24",
"statements": [
{
"nodeType": "YulAssignment",
"src": "2638:14:24",
"value": {
"name": "slot",
"nodeType": "YulIdentifier",
"src": "2648:4:24"
},
"variableNames": [
{
"name": "r.slot",
"nodeType": "YulIdentifier",
"src": "2638:6:24"
}
]
}
]
},
"documentation": "@solidity memory-safe-assembly",
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 18441,
"isOffset": false,
"isSlot": true,
"src": "2638:6:24",
"suffix": "slot",
"valueSize": 1
},
{
"declaration": 18437,
"isOffset": false,
"isSlot": false,
"src": "2648:4:24",
"valueSize": 1
}
],
"id": 18443,
"nodeType": "InlineAssembly",
"src": "2615:47:24"
}
]
},
"documentation": {
"id": 18435,
"nodeType": "StructuredDocumentation",
"src": "2386:87:24",
"text": " @dev Returns an `Uint256Slot` with member `value` located at `slot`."
},
"id": 18445,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "getUint256Slot",
"nameLocation": "2487:14:24",
"nodeType": "FunctionDefinition",
"parameters": {
"id": 18438,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18437,
"mutability": "mutable",
"name": "slot",
"nameLocation": "2510:4:24",
"nodeType": "VariableDeclaration",
"scope": 18445,
"src": "2502:12:24",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 18436,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2502:7:24",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"visibility": "internal"
}
],
"src": "2501:14:24"
},
"returnParameters": {
"id": 18442,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 18441,
"mutability": "mutable",
"name": "r",
"nameLocation": "2559:1:24",
"nodeType": "VariableDeclaration",
"scope": 18445,
"src": "2539:21:24",
"stateVariable": false,
"storageLocation": "storage",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Uint256Slot_$18401_storage_ptr",
"typeString": "struct StorageSlot.Uint256Slot"
},
"typeName": {
"id": 18440,
"nodeType": "UserDefinedTypeName",
"pathNode": {
"id": 18439,
"name": "Uint256Slot",
"nameLocations": [
"2539:11:24"
],
"nodeType": "IdentifierPath",
"referencedDeclaration": 18401,
"src": "2539:11:24"
},
"referencedDeclaration": 18401,
"src": "2539:11:24",
"typeDescriptions": {
"typeIdentifier": "t_struct$_Uint256Slot_$18401_storage_ptr",
"typeString": "struct StorageSlot.Uint256Slot"
}
},
"visibility": "internal"
}
],
"src": "2538:23:24"
},
"scope": 18446,
"src": "2478:190:24",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
}
],
"scope": 18447,
"src": "1279:1391:24",
"usedErrors": []
}
],
"src": "105:2566:24"
},
"bytecode": "60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122005a9f0817fee738df283c357d68597db54656c50e5b819f6ac60c81d1dfcb22364736f6c63430008130033",
"bytecodeSha1": "1ce946f6a4eaa185320328620ccf999b9e86db7c",
"compiler": {
"evm_version": "istanbul",
"optimizer": {
"enabled": true,
"runs": 200
},
"version": "0.8.19+commit.7dd6d404"
},
"contractName": "StorageSlot",
"coverageMap": {
"branches": {
"24": {}
},
"statements": {
"24": {}
}
},
"dependencies": [],
"deployedBytecode": "73000000000000000000000000000000000000000030146080604052600080fdfea264697066735822122005a9f0817fee738df283c357d68597db54656c50e5b819f6ac60c81d1dfcb22364736f6c63430008130033",
"deployedSourceMap": "1279:1391:24:-:0;;;;;;;;",
"language": "Solidity",
"natspec": {
"details": "Library for reading and writing primitive types to specific storage slots. Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. This library helps with reading and writing to such slots without the need for inline assembly. The functions in this library return Slot structs that contain a `value` member that can be used to read or write. Example usage to set ERC1967 implementation slot: ``` contract ERC1967 { bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; function _getImplementation() internal view returns (address) { return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; } function _setImplementation(address newImplementation) internal { require(Address.isContract(newImplementation), \"ERC1967: new implementation is not a contract\"); StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; } } ``` _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._",
"kind": "dev",
"methods": {},
"version": 1
},
"offset": [
1279,
2670
],
"opcodes": "PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 SDIV 0xA9 CREATE DUP2 PUSH32 0xEE738DF283C357D68597DB54656C50E5B819F6AC60C81D1DFCB22364736F6C63 NUMBER STOP ADDMOD SGT STOP CALLER ",
"pcMap": {
"0": {
"offset": [
1279,
2670
],
"op": "PUSH20",
"path": "24",
"value": "0x0"
},
"21": {
"fn": null,
"offset": [
1279,
2670
],
"op": "ADDRESS",
"path": "24"
},
"22": {
"fn": null,
"offset": [
1279,
2670
],
"op": "EQ",
"path": "24"
},
"23": {
"fn": null,
"offset": [
1279,
2670
],
"op": "PUSH1",
"path": "24",
"value": "0x80"
},
"25": {
"fn": null,
"offset": [
1279,
2670
],
"op": "PUSH1",
"path": "24",
"value": "0x40"
},
"27": {
"fn": null,
"offset": [
1279,
2670
],
"op": "MSTORE",
"path": "24"
},
"28": {
"fn": null,
"offset": [
1279,
2670
],
"op": "PUSH1",
"path": "24",
"value": "0x0"
},
"30": {
"fn": null,
"offset": [
1279,
2670
],
"op": "DUP1",
"path": "24"
},
"31": {
"fn": null,
"offset": [
1279,
2670
],
"op": "REVERT",
"path": "24"
}
},
"sha1": "4c48fbf403a420a06f911e66a5f61af169dbf236",
"source": "// SPDX-License-Identifier: MIT\n// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol)\n\npragma solidity ^0.8.0;\n\n/**\n * @dev Library for reading and writing primitive types to specific storage slots.\n *\n * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts.\n * This library helps with reading and writing to such slots without the need for inline assembly.\n *\n * The functions in this library return Slot structs that contain a `value` member that can be used to read or write.\n *\n * Example usage to set ERC1967 implementation slot:\n * ```\n * contract ERC1967 {\n * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc;\n *\n * function _getImplementation() internal view returns (address) {\n * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value;\n * }\n *\n * function _setImplementation(address newImplementation) internal {\n * require(Address.isContract(newImplementation), \"ERC1967: new implementation is not a contract\");\n * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation;\n * }\n * }\n * ```\n *\n * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._\n */\nlibrary StorageSlot {\n struct AddressSlot {\n address value;\n }\n\n struct BooleanSlot {\n bool value;\n }\n\n struct Bytes32Slot {\n bytes32 value;\n }\n\n struct Uint256Slot {\n uint256 value;\n }\n\n /**\n * @dev Returns an `AddressSlot` with member `value` located at `slot`.\n */\n function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `BooleanSlot` with member `value` located at `slot`.\n */\n function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `Bytes32Slot` with member `value` located at `slot`.\n */\n function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n\n /**\n * @dev Returns an `Uint256Slot` with member `value` located at `slot`.\n */\n function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) {\n /// @solidity memory-safe-assembly\n assembly {\n r.slot := slot\n }\n }\n}\n",
"sourceMap": "1279:1391:24:-:0;;;;;;;;;;;;;;;-1:-1:-1;;;1279:1391:24;;;;;;;;;;;;;;;;;",
"sourcePath": "/home/vscode/.brownie/packages/OpenZeppelin/openzeppelin-contracts@4.8.2/contracts/utils/StorageSlot.sol",
"type": "library"
}