Merge pull request #3182 from janat08/patch-2

Update introduction-to-smart-contracts.rst
This commit is contained in:
chriseth 2018-02-19 16:52:45 +01:00 committed by GitHub
commit a938e39a9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -118,9 +118,11 @@ that is publicly accessible. The ``address`` type is a 160-bit value
that does not allow any arithmetic operations. It is suitable for
storing addresses of contracts or keypairs belonging to external
persons. The keyword ``public`` automatically generates a function that
allows you to access the current value of the state variable.
allows you to access the current value of the state variable
from outside of the contract.
Without this keyword, other contracts have no way to access the variable.
The function will look something like this::
The code of the function generated by the compiler is roughly equivalent
to the following::
function minter() returns (address) { return minter; }