4

When a contract triggers a throw, the Solidity document states:

Solidity will trigger an "invalid jump" and thus cause the EVM to revert all changes made to the state.

In this case, what happens to the ether value (not the gas) that was sent along with the transaction? Is it returned to the sender, or is it still stored in the contract?

5

The ether value that was sent along with the transaction (or call if the exception is caught) is returned to the sender if you use throw in Solidity.

4

Yes, all funds are returned to the sender, except the gas. https://github.com/ethereum/wiki/wiki/Solidity-Features#throw

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.