{
  "contractName": "IsContract",
  "abi": [],
  "metadata": "{\"compiler\":{\"version\":\"0.4.24+commit.e67f0147\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"@aragon/os/contracts/common/IsContract.sol\":\"IsContract\"},\"evmVersion\":\"byzantium\",\"libraries\":{},\"optimizer\":{\"enabled\":true,\"runs\":10000},\"remappings\":[]},\"sources\":{\"@aragon/os/contracts/common/IsContract.sol\":{\"keccak256\":\"0xb76e263e3532883fe32dfe4b1447eb487a570e121c5cce01cee604dd9e44a075\",\"urls\":[\"bzzr://4a7dd7aafff496a2c6403a7e9f4e74562088b5a38e2f6e2670e38dab11b9cd8f\"]}},\"version\":1}",
  "bytecode": "0x6080604052348015600f57600080fd5b50603580601d6000396000f3006080604052600080fd00a165627a7a723058207e3915f8ef11fda157b2040b87df112745d09a818078627240e5f75b2eb72f020029",
  "deployedBytecode": "0x6080604052600080fd00a165627a7a723058207e3915f8ef11fda157b2040b87df112745d09a818078627240e5f75b2eb72f020029",
  "sourceMap": "71:601:31:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;71:601:31;;;;;;;",
  "deployedSourceMap": "71:601:31:-;;;;;",
  "source": "/*\n * SPDX-License-Identitifer:    MIT\n */\n\npragma solidity ^0.4.24;\n\n\ncontract IsContract {\n    /*\n    * NOTE: this should NEVER be used for authentication\n    * (see pitfalls: https://github.com/fergarrui/ethereum-security/tree/master/contracts/extcodesize).\n    *\n    * This is only intended to be used as a sanity check that an address is actually a contract,\n    * RATHER THAN an address not being a contract.\n    */\n    function isContract(address _target) internal view returns (bool) {\n        if (_target == address(0)) {\n            return false;\n        }\n\n        uint256 size;\n        assembly { size := extcodesize(_target) }\n        return size > 0;\n    }\n}\n",
  "sourcePath": "@aragon/os/contracts/common/IsContract.sol",
  "ast": {
    "absolutePath": "@aragon/os/contracts/common/IsContract.sol",
    "exportedSymbols": {
      "IsContract": [
        6469
      ]
    },
    "id": 6470,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 6443,
        "literals": [
          "solidity",
          "^",
          "0.4",
          ".24"
        ],
        "nodeType": "PragmaDirective",
        "src": "44:24:31"
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "contract",
        "documentation": null,
        "fullyImplemented": true,
        "id": 6469,
        "linearizedBaseContracts": [
          6469
        ],
        "name": "IsContract",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "body": {
              "id": 6467,
              "nodeType": "Block",
              "src": "492:178:31",
              "statements": [
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    },
                    "id": 6454,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 6450,
                      "name": "_target",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6445,
                      "src": "506:7:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 6452,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "525:1:31",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          }
                        ],
                        "id": 6451,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "517:7:31",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 6453,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "517:10:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "506:21:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 6458,
                  "nodeType": "IfStatement",
                  "src": "502:64:31",
                  "trueBody": {
                    "id": 6457,
                    "nodeType": "Block",
                    "src": "529:37:31",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "hexValue": "66616c7365",
                          "id": 6455,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "bool",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "550:5:31",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          "value": "false"
                        },
                        "functionReturnParameters": 6449,
                        "id": 6456,
                        "nodeType": "Return",
                        "src": "543:12:31"
                      }
                    ]
                  }
                },
                {
                  "assignments": [],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 6460,
                      "name": "size",
                      "nodeType": "VariableDeclaration",
                      "scope": 6468,
                      "src": "576:12:31",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 6459,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "576:7:31",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 6461,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "576:12:31"
                },
                {
                  "externalReferences": [
                    {
                      "size": {
                        "declaration": 6460,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "609:4:31",
                        "valueSize": 1
                      }
                    },
                    {
                      "_target": {
                        "declaration": 6445,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "629:7:31",
                        "valueSize": 1
                      }
                    }
                  ],
                  "id": 6462,
                  "nodeType": "InlineAssembly",
                  "operations": "{\n    size := extcodesize(_target)\n}",
                  "src": "598:56:31"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 6465,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 6463,
                      "name": "size",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6460,
                      "src": "655:4:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 6464,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "662:1:31",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "655:8:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 6449,
                  "id": 6466,
                  "nodeType": "Return",
                  "src": "648:15:31"
                }
              ]
            },
            "documentation": null,
            "id": 6468,
            "implemented": true,
            "isConstructor": false,
            "isDeclaredConst": true,
            "modifiers": [],
            "name": "isContract",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 6446,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6445,
                  "name": "_target",
                  "nodeType": "VariableDeclaration",
                  "scope": 6468,
                  "src": "446:15:31",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6444,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "446:7:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "445:17:31"
            },
            "payable": false,
            "returnParameters": {
              "id": 6449,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6448,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 6468,
                  "src": "486:4:31",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 6447,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "486:4:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "485:6:31"
            },
            "scope": 6469,
            "src": "426:244:31",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "internal"
          }
        ],
        "scope": 6470,
        "src": "71:601:31"
      }
    ],
    "src": "44:629:31"
  },
  "legacyAST": {
    "absolutePath": "@aragon/os/contracts/common/IsContract.sol",
    "exportedSymbols": {
      "IsContract": [
        6469
      ]
    },
    "id": 6470,
    "nodeType": "SourceUnit",
    "nodes": [
      {
        "id": 6443,
        "literals": [
          "solidity",
          "^",
          "0.4",
          ".24"
        ],
        "nodeType": "PragmaDirective",
        "src": "44:24:31"
      },
      {
        "baseContracts": [],
        "contractDependencies": [],
        "contractKind": "contract",
        "documentation": null,
        "fullyImplemented": true,
        "id": 6469,
        "linearizedBaseContracts": [
          6469
        ],
        "name": "IsContract",
        "nodeType": "ContractDefinition",
        "nodes": [
          {
            "body": {
              "id": 6467,
              "nodeType": "Block",
              "src": "492:178:31",
              "statements": [
                {
                  "condition": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    },
                    "id": 6454,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 6450,
                      "name": "_target",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6445,
                      "src": "506:7:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": "==",
                    "rightExpression": {
                      "argumentTypes": null,
                      "arguments": [
                        {
                          "argumentTypes": null,
                          "hexValue": "30",
                          "id": 6452,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "number",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "525:1:31",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          },
                          "value": "0"
                        }
                      ],
                      "expression": {
                        "argumentTypes": [
                          {
                            "typeIdentifier": "t_rational_0_by_1",
                            "typeString": "int_const 0"
                          }
                        ],
                        "id": 6451,
                        "isConstant": false,
                        "isLValue": false,
                        "isPure": true,
                        "lValueRequested": false,
                        "nodeType": "ElementaryTypeNameExpression",
                        "src": "517:7:31",
                        "typeDescriptions": {
                          "typeIdentifier": "t_type$_t_address_$",
                          "typeString": "type(address)"
                        },
                        "typeName": "address"
                      },
                      "id": 6453,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "typeConversion",
                      "lValueRequested": false,
                      "names": [],
                      "nodeType": "FunctionCall",
                      "src": "517:10:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_address",
                        "typeString": "address"
                      }
                    },
                    "src": "506:21:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "falseBody": null,
                  "id": 6458,
                  "nodeType": "IfStatement",
                  "src": "502:64:31",
                  "trueBody": {
                    "id": 6457,
                    "nodeType": "Block",
                    "src": "529:37:31",
                    "statements": [
                      {
                        "expression": {
                          "argumentTypes": null,
                          "hexValue": "66616c7365",
                          "id": 6455,
                          "isConstant": false,
                          "isLValue": false,
                          "isPure": true,
                          "kind": "bool",
                          "lValueRequested": false,
                          "nodeType": "Literal",
                          "src": "550:5:31",
                          "subdenomination": null,
                          "typeDescriptions": {
                            "typeIdentifier": "t_bool",
                            "typeString": "bool"
                          },
                          "value": "false"
                        },
                        "functionReturnParameters": 6449,
                        "id": 6456,
                        "nodeType": "Return",
                        "src": "543:12:31"
                      }
                    ]
                  }
                },
                {
                  "assignments": [],
                  "declarations": [
                    {
                      "constant": false,
                      "id": 6460,
                      "name": "size",
                      "nodeType": "VariableDeclaration",
                      "scope": 6468,
                      "src": "576:12:31",
                      "stateVariable": false,
                      "storageLocation": "default",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      },
                      "typeName": {
                        "id": 6459,
                        "name": "uint256",
                        "nodeType": "ElementaryTypeName",
                        "src": "576:7:31",
                        "typeDescriptions": {
                          "typeIdentifier": "t_uint256",
                          "typeString": "uint256"
                        }
                      },
                      "value": null,
                      "visibility": "internal"
                    }
                  ],
                  "id": 6461,
                  "initialValue": null,
                  "nodeType": "VariableDeclarationStatement",
                  "src": "576:12:31"
                },
                {
                  "externalReferences": [
                    {
                      "size": {
                        "declaration": 6460,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "609:4:31",
                        "valueSize": 1
                      }
                    },
                    {
                      "_target": {
                        "declaration": 6445,
                        "isOffset": false,
                        "isSlot": false,
                        "src": "629:7:31",
                        "valueSize": 1
                      }
                    }
                  ],
                  "id": 6462,
                  "nodeType": "InlineAssembly",
                  "operations": "{\n    size := extcodesize(_target)\n}",
                  "src": "598:56:31"
                },
                {
                  "expression": {
                    "argumentTypes": null,
                    "commonType": {
                      "typeIdentifier": "t_uint256",
                      "typeString": "uint256"
                    },
                    "id": 6465,
                    "isConstant": false,
                    "isLValue": false,
                    "isPure": false,
                    "lValueRequested": false,
                    "leftExpression": {
                      "argumentTypes": null,
                      "id": 6463,
                      "name": "size",
                      "nodeType": "Identifier",
                      "overloadedDeclarations": [],
                      "referencedDeclaration": 6460,
                      "src": "655:4:31",
                      "typeDescriptions": {
                        "typeIdentifier": "t_uint256",
                        "typeString": "uint256"
                      }
                    },
                    "nodeType": "BinaryOperation",
                    "operator": ">",
                    "rightExpression": {
                      "argumentTypes": null,
                      "hexValue": "30",
                      "id": 6464,
                      "isConstant": false,
                      "isLValue": false,
                      "isPure": true,
                      "kind": "number",
                      "lValueRequested": false,
                      "nodeType": "Literal",
                      "src": "662:1:31",
                      "subdenomination": null,
                      "typeDescriptions": {
                        "typeIdentifier": "t_rational_0_by_1",
                        "typeString": "int_const 0"
                      },
                      "value": "0"
                    },
                    "src": "655:8:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "functionReturnParameters": 6449,
                  "id": 6466,
                  "nodeType": "Return",
                  "src": "648:15:31"
                }
              ]
            },
            "documentation": null,
            "id": 6468,
            "implemented": true,
            "isConstructor": false,
            "isDeclaredConst": true,
            "modifiers": [],
            "name": "isContract",
            "nodeType": "FunctionDefinition",
            "parameters": {
              "id": 6446,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6445,
                  "name": "_target",
                  "nodeType": "VariableDeclaration",
                  "scope": 6468,
                  "src": "446:15:31",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_address",
                    "typeString": "address"
                  },
                  "typeName": {
                    "id": 6444,
                    "name": "address",
                    "nodeType": "ElementaryTypeName",
                    "src": "446:7:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_address",
                      "typeString": "address"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "445:17:31"
            },
            "payable": false,
            "returnParameters": {
              "id": 6449,
              "nodeType": "ParameterList",
              "parameters": [
                {
                  "constant": false,
                  "id": 6448,
                  "name": "",
                  "nodeType": "VariableDeclaration",
                  "scope": 6468,
                  "src": "486:4:31",
                  "stateVariable": false,
                  "storageLocation": "default",
                  "typeDescriptions": {
                    "typeIdentifier": "t_bool",
                    "typeString": "bool"
                  },
                  "typeName": {
                    "id": 6447,
                    "name": "bool",
                    "nodeType": "ElementaryTypeName",
                    "src": "486:4:31",
                    "typeDescriptions": {
                      "typeIdentifier": "t_bool",
                      "typeString": "bool"
                    }
                  },
                  "value": null,
                  "visibility": "internal"
                }
              ],
              "src": "485:6:31"
            },
            "scope": 6469,
            "src": "426:244:31",
            "stateMutability": "view",
            "superFunction": null,
            "visibility": "internal"
          }
        ],
        "scope": 6470,
        "src": "71:601:31"
      }
    ],
    "src": "44:629:31"
  },
  "compiler": {
    "name": "solc",
    "version": "0.4.24+commit.e67f0147.Emscripten.clang"
  },
  "networks": {},
  "schemaVersion": "3.2.0",
  "updatedAt": "2020-06-07T23:27:00.574Z",
  "devdoc": {
    "methods": {}
  },
  "userdoc": {
    "methods": {}
  }
}