Commit Graph

235 Commits

Author SHA1 Message Date
Hector Roussille
040c444a2a Fixed ambiguity in the create2 address computation doc
specify that arguments are encoded using abi.encode in the example code
2022-03-16 19:56:11 +01:00
Braden Watling
bb16c1943c Fix gas retaining statement.
According to https://docs.soliditylang.org/en/v0.8.11/introduction-to-smart-contracts.html?highlight=63%2F64#message-calls, the caller forwards 63/64th of its gas, but here we seem to contradict that by saying the caller retains 63/64th of its gas.
2022-01-04 11:10:31 +01:00
Braden Watling
6fe1ee6a8a
Fix typo in control-structures.rst
I'm learning Solidity by reading these docs and found this statement confusing. I'm fairly certain that the correct description here is that the *callee* changes get reverted, but the caller is able to react to the failures.

I tested this with the following snippet in Remix, which resulted in a successful transaction when deployed:

```
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.7;

contract A {
    uint public value;

    function a(uint newValue, bool shouldRevert) external {
        value = newValue;
        if (shouldRevert) {
            revert();
        }
    }
}

contract B {
    function b() external {
        A a = new A();
        try a.a(50, false) {
            assert(a.value() == 50);
        } catch {
            assert(false);
        }
        a = new A();
        try a.a(50, true) {
            assert(false);
        } catch {
            assert(a.value() == 0);
        }
    }
}
```
2022-01-03 17:22:23 -05:00
GitHubPang
1b0cef4624
Fix a few typos 2021-12-20 10:56:39 +08:00
chriseth
f320a95dd9 Update documentation. 2021-11-08 14:58:09 +01:00
Adam Bliss
3387e134d7
Fix typo compiler->constructor. 2021-10-24 08:22:34 -04:00
istareatscreens
d1465dd0f7 Reword External Function Calls paragraph in docs
Reword External Function Calls opening paragraph to improve clarity
2021-09-14 17:51:18 -04:00
chriseth
9033660b22 Clarify function call options example. 2021-08-31 14:32:32 +02:00
Kamil Śliwak
693b88e5f8 docs: Force highlighter to work despite errors on snippets that it cannot parse 2021-07-15 10:14:00 +02:00
Kamil Śliwak
d8260a1e93 docs: Replace > with >= in pragmas to work around the highligher being unable to process the former 2021-07-15 10:14:00 +02:00
iskanderandrews
a8e9d7a80d docs/
Enhancing all the .rst doc files by adding highlighting for the code snippets, including the following langs:
1. Solidity

2. bash

3. javascript

4. assembly
2021-06-25 12:33:55 +02:00
Mathias Baumann
d8ffdf11c8 Fix revert pruner modifying function flows wrong 2021-06-03 17:37:50 +02:00
Alex Beregszaszi
bf2c82adca Document the panic function of library deployment 2021-05-26 15:51:46 +01:00
hrkrshnn
d9c57dd1fb Added index for safemath in docs 2021-04-08 17:39:04 +02:00
chriseth
99a9bd1a63
Merge pull request #11176 from ethereum/random-doc-clarifications
Random documentation clarifications
2021-04-01 14:47:54 +02:00
chriseth
0c1be06cba Documentation for custom errors. 2021-03-30 23:04:32 +02:00
Kamil Śliwak
879f1b3e26 docs: Mention that low-level calls do not have an extcodesize check 2021-03-30 18:10:00 +02:00
Kamil Śliwak
93bfc76216 docs: Mention explicitly that bitwise operators do not perform overflow/underflow checks 2021-03-30 14:31:51 +02:00
chriseth
df7c17a053 Document `catch Panic(uint)`. 2021-01-14 18:37:02 +01:00
chriseth
191070d322 Remove version pragmas using .99. 2020-12-16 19:39:02 +00:00
Alex Beregszaszi
15237c8404 Disable the type byte 2020-12-14 19:18:25 +00:00
hrkrshnn
40244c5469 Tests/Docs after stricter explicit conversion. 2020-12-03 16:51:05 +01:00
chriseth
b1cfb5506d Clarify forwarding of error data. 2020-11-24 12:28:04 +01:00
chriseth
d744a8fb48 Fail on invalid storage encoding for byte arrays. 2020-11-12 11:12:42 +01:00
chriseth
e93a84ccd4 Merge remote-tracking branch 'origin/develop' into HEAD 2020-10-28 18:19:31 +01:00
chriseth
70e7326695 Document Panic. 2020-10-22 19:26:26 +02:00
chriseth
b4771f2a1c Clarify evaluation of arguments to require. 2020-10-22 18:07:02 +02:00
chriseth
e262f47f21 Documentation. 2020-10-19 16:58:59 +02:00
chriseth
8a1bf41ac0
Merge pull request #10010 from ethereum/develop
Merge develop into breaking.
2020-10-12 15:33:34 +02:00
chriseth
ca86eacfb2 Remove traces of errors due to shifts by negative amounts. 2020-10-08 20:24:53 +02:00
chriseth
4bdec8107c Merge remote-tracking branch 'origin/develop' into HEAD 2020-09-29 09:53:50 +02:00
Harikrishnan Mulackal
8339765509 [DOCS] Change >=0.7.0 to ^0.7.0 2020-09-28 13:02:31 +02:00
Harikrishnan Mulackal
710231e2b1 Docs: change >0.6.99 <0.8.0 to >=0.7.0 2020-09-28 11:14:45 +02:00
chriseth
0c6dc1dce4
Merge pull request #9862 from ethereum/develop
Merge develop into breaking
2020-09-23 12:22:32 +02:00
chriseth
71af44b27b Add note about extcodesize check. 2020-09-21 11:58:23 +02:00
chriseth
efe829b4b2
Merge pull request #9805 from ethereum/develop
Merge develop into breaking.
2020-09-14 20:48:03 +02:00
Omkar Nikhal
55a7173e27
Update control-structures.rst 2020-09-12 12:50:36 +05:30
Mathias Baumann
b72fb1333b Adjust docs example to work with v0.8.0 2020-09-08 13:36:16 +02:00
chriseth
479d7a059f Documentation. 2020-07-07 12:16:18 +02:00
chriseth
74b9b094c0 Merge remote-tracking branch 'origin/develop' into HEAD 2020-05-20 17:22:47 +02:00
Alexander Arlt
af8bb5fb60 Allow natspec comments on state variables. 2020-05-19 11:01:52 -05:00
chriseth
257bc6a416 Merge remote-tracking branch 'origin/develop' into breaking 2020-05-14 13:04:46 +02:00
chriseth
d33b67b3c2 Add license tags to documentation snippets. 2020-05-13 22:16:34 +02:00
hrkrshnn
bd0b06e8db Tests, Docs and Changelog 2020-04-28 16:03:52 +05:30
chriseth
7d68f9f6c3 Merge remote-tracking branch 'origin/develop' into breaking 2020-03-24 13:35:41 +01:00
Erik Kundt
50c22f0800 Adds script which compiles docs example with minimum compiler version. 2020-03-18 19:27:38 +01:00
chriseth
9d92c9fbf1 Merge remote-tracking branch 'origin/develop' into HEAD 2020-03-11 18:44:06 +01:00
chriseth
cdfb872389 [DOCS] Fix pre-computation of salted address. 2020-03-08 19:15:21 +01:00
chriseth
06ad5b3200 Merge remote-tracking branch 'origin/develop' into HEAD 2020-02-27 15:06:36 +01:00
Chris Chinchilla
9641d93167 Clarify array copying semantics 2020-02-18 16:50:34 +02:00