diff options
author | chriseth <chris@ethereum.org> | 2018-05-16 15:37:58 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-16 15:37:58 +0800 |
commit | 7f965c8671cbbd538fd0dada5a936dc58687d029 (patch) | |
tree | c76fa0ada18d4318dcb58c19a18eef47df990e8a /docs/solidity-by-example.rst | |
parent | 2ba0002998d12ea412f17d55b643ec85c02e6a30 (diff) | |
parent | 3ca6738114f9ae410c7488a1b1d66eeec92833c6 (diff) | |
download | dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar.gz dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar.bz2 dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar.lz dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar.xz dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.tar.zst dexon-solidity-7f965c8671cbbd538fd0dada5a936dc58687d029.zip |
Merge pull request #4004 from ethereum/mulitVariableAssignment
Multi variable declarations
Diffstat (limited to 'docs/solidity-by-example.rst')
-rw-r--r-- | docs/solidity-by-example.rst | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/docs/solidity-by-example.rst b/docs/solidity-by-example.rst index f6038f7d..2b3d4b48 100644 --- a/docs/solidity-by-example.rst +++ b/docs/solidity-by-example.rst @@ -388,7 +388,7 @@ high or low invalid bids. :: - pragma solidity ^0.4.22; + pragma solidity >0.4.23 <0.5.0; contract BlindAuction { struct Bid { @@ -467,8 +467,8 @@ high or low invalid bids. uint refund; for (uint i = 0; i < length; i++) { - var bid = bids[msg.sender][i]; - var (value, fake, secret) = + Bid storage bid = bids[msg.sender][i]; + (uint value, bool fake, bytes32 secret) = (_values[i], _fake[i], _secret[i]); if (bid.blindedBid != keccak256(value, fake, secret)) { // Bid was not actually revealed. |