diff options
author | Chris Ward <chris.ward@ethereum.org> | 2019-01-16 20:50:50 +0800 |
---|---|---|
committer | Chris Ward <chris.ward@ethereum.org> | 2019-01-16 20:50:50 +0800 |
commit | b58a6a4a04ef10d19b24cf80866bfce33091136d (patch) | |
tree | c82684b6bc159763e45168cca38501d18bc2ab32 | |
parent | 778b14de260a7eeaea88867e39cfc226f1494e63 (diff) | |
download | dexon-solidity-b58a6a4a04ef10d19b24cf80866bfce33091136d.tar.gz dexon-solidity-b58a6a4a04ef10d19b24cf80866bfce33091136d.tar.zst dexon-solidity-b58a6a4a04ef10d19b24cf80866bfce33091136d.zip |
Remove FAQ item
-rw-r--r-- | docs/frequently-asked-questions.rst | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/docs/frequently-asked-questions.rst b/docs/frequently-asked-questions.rst index 4635d577..1c24eef1 100644 --- a/docs/frequently-asked-questions.rst +++ b/docs/frequently-asked-questions.rst @@ -108,36 +108,6 @@ In this example:: } } -Can a contract pass an array (static size) or string or ``bytes`` (dynamic size) to another contract? -===================================================================================================== - -Sure. Take care that if you cross the memory / storage boundary, -independent copies will be created:: - - pragma solidity >=0.4.16 <0.6.0; - - contract C { - uint[20] x; - - function f() public { - g(x); - h(x); - } - - function g(uint[20] memory y) internal pure { - y[2] = 3; - } - - function h(uint[20] storage y) internal { - y[3] = 4; - } - } - -The call to ``g(x)`` will not have an effect on ``x`` because it needs -to create an independent copy of the storage value in memory. -On the other hand, ``h(x)`` successfully modifies ``x`` because only -a reference and not a copy is passed. - What does the following strange check do in the Custom Token contract? ====================================================================== |