diff options
author | chriseth <chris@ethereum.org> | 2017-06-06 21:02:34 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-06 21:02:34 +0800 |
commit | 243e389fd7b3dc6c893c6021514d04f3b2bb035e (patch) | |
tree | e354c23f8ded05f8a52163969dd067dbaa2e6f21 | |
parent | 60f9fee40b9581deb33ee6fddec424a249e68429 (diff) | |
parent | 8595bc7122c9e0cb34b558446cb959ec3e30cc81 (diff) | |
download | dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar.gz dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar.bz2 dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar.lz dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar.xz dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.tar.zst dexon-solidity-243e389fd7b3dc6c893c6021514d04f3b2bb035e.zip |
Merge pull request #2341 from ethernomad/patch-3
for free => automatically
-rw-r--r-- | docs/miscellaneous.rst | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/miscellaneous.rst b/docs/miscellaneous.rst index 914dfacd..2e0ccf45 100644 --- a/docs/miscellaneous.rst +++ b/docs/miscellaneous.rst @@ -371,7 +371,7 @@ Tips and Tricks * Use ``delete`` on arrays to delete all its elements. * Use shorter types for struct elements and sort them such that short types are grouped together. This can lower the gas costs as multiple SSTORE operations might be combined into a single (SSTORE costs 5000 or 20000 gas, so this is what you want to optimise). Use the gas price estimator (with optimiser enabled) to check! -* Make your state variables public - the compiler will create :ref:`getters <visibility-and-getters>` for you for free. +* Make your state variables public - the compiler will create :ref:`getters <visibility-and-getters>` for you automatically. * If you end up checking conditions on input or state a lot at the beginning of your functions, try using :ref:`modifiers`. * If your contract has a function called ``send`` but you want to use the built-in send-function, use ``address(contractVariable).send(amount)``. * Initialise storage structs with a single assignment: ``x = MyStruct({a: 1, b: 2});`` |