I am trying to deploy a contract which has an external function with no implementation body. Remix and truffle have problems with this. I know that abstract interfaces can't be deployed, but how were contracts like this deployed? The deposit function is empty :https://etherscan.io/address/0xc7029Ed9EBa97A096e72607f4340c34049C7AF48#code

My contract has a function similar to

    function deposit()
    payable { }

I planned to reference my deployed contract using something like:

DeployedInterface constant private DeployedCOntract = DeployedInterface(deployedInterfaceAddress);
  • You can deploy a function with an empty body just fine. What you can't do is deploy a function with no body. (E.g. foo() { } is fine, but foo(); is not.) – smarx Sep 6 '18 at 15:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.