-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cleaned up and modified global variables documentation #612
Conversation
Address Related | ||
--------------- | ||
|
||
``<address>.balance`` (``uint256``): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add links to the address type here and from the address type to here, so that we do not forget updating both if something changes.
To be sure that your contract can receive Ether in that way, check the gas requirements of the fallback function. | ||
- If you want to send ether using ``address.send``, there are certain details to be aware of: | ||
1. If the recipient is a contract, it causes its fallback function to be executed which can in turn call back into the sending contract | ||
2. Sending Ether can fail due to the call depth going above 1024. Since the caller is in total control of the call |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the maximum call depth? Is it >1024 or >= 1024? This line, and the line mentioning 1023, makes this a little confusing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The maximum depth is 1024, but it is not clear whether the first call is at depth 0 or at depth 1 :-)
Updated. Also, it actually passes the Travis CI build now. |
``<address>.send(uint256 amount) returns (bool)``: | ||
send given amount of Wei to address, returns ``false`` on failure | ||
|
||
For more information, see the section on :ref:`address`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did you delete this line?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I incorporated the links into the lines above, in the description. This is more in line with how it was done in other sections, like the one right below it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But now it does not say anymore that more information can be found behind that link. Shouldn't we mention that?
Alright, added that section back in. |
No description provided.