aboutsummaryrefslogtreecommitdiffstats
path: root/docs/abi-spec.rst
diff options
context:
space:
mode:
authorAlex Beregszaszi <alex@rtfs.hu>2017-11-22 12:59:28 +0800
committerGitHub <noreply@github.com>2017-11-22 12:59:28 +0800
commitbe34b574bf386faf414001c7cb11063c6fe7b6f6 (patch)
tree25f310690066730ba0da1ee2f63318b520f7d06f /docs/abi-spec.rst
parentb7fb1bc0a6e7311bf09118c228ba8d93dc944328 (diff)
parent744dea60a40e7e5cb25814c3f6f6eb01dc767698 (diff)
downloaddexon-solidity-be34b574bf386faf414001c7cb11063c6fe7b6f6.tar.gz
dexon-solidity-be34b574bf386faf414001c7cb11063c6fe7b6f6.tar.zst
dexon-solidity-be34b574bf386faf414001c7cb11063c6fe7b6f6.zip
Merge pull request #3152 from ethereum/docs-tests
Ensure each code snippet in the docs can be extracted for tests
Diffstat (limited to 'docs/abi-spec.rst')
-rw-r--r--docs/abi-spec.rst26
1 files changed, 13 insertions, 13 deletions
diff --git a/docs/abi-spec.rst b/docs/abi-spec.rst
index 77d15026..8bd6d1a7 100644
--- a/docs/abi-spec.rst
+++ b/docs/abi-spec.rst
@@ -330,15 +330,15 @@ For example,
::
- pragma solidity ^0.4.0;
+ pragma solidity ^0.4.0;
- contract Test {
- function Test(){ b = 0x12345678901234567890123456789012; }
- event Event(uint indexed a, bytes32 b);
- event Event2(uint indexed a, bytes32 b);
- function foo(uint a) { Event(a, b); }
- bytes32 b;
- }
+ contract Test {
+ function Test(){ b = 0x12345678901234567890123456789012; }
+ event Event(uint indexed a, bytes32 b);
+ event Event2(uint indexed a, bytes32 b);
+ function foo(uint a) { Event(a, b); }
+ bytes32 b;
+ }
would result in the JSON:
@@ -377,11 +377,11 @@ As an example, the code
::
- contract Test {
- struct S { uint a; uint[] b; T[] c; }
- struct T { uint x; uint y; }
- function f(S s, T t, uint a) { }
- }
+ contract Test {
+ struct S { uint a; uint[] b; T[] c; }
+ struct T { uint x; uint y; }
+ function f(S s, T t, uint a) { }
+ }
would result in the JSON: