diff options
author | chenquan <terasum@163.com> | 2018-01-05 20:43:24 +0800 |
---|---|---|
committer | chenquan <terasum@163.com> | 2018-01-05 20:43:24 +0800 |
commit | d0d952283776dd7a99f4b575e34f8a345ba01130 (patch) | |
tree | 3538eada3231357e8d8d384e43ea3add0e3306a6 /docs | |
parent | 42cc3915feaa85ec562d9496e92b50ac59edfdb3 (diff) | |
parent | 35095e9fcc53f76a1c73251497c265f399a9896c (diff) | |
download | dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar.gz dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar.bz2 dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar.lz dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar.xz dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.tar.zst dexon-solidity-d0d952283776dd7a99f4b575e34f8a345ba01130.zip |
Merge branch 'develop' of https://github.com/ethereum/solidity into develop
Diffstat (limited to 'docs')
-rw-r--r-- | docs/grammar.txt | 17 | ||||
-rw-r--r-- | docs/julia.rst | 7 |
2 files changed, 18 insertions, 6 deletions
diff --git a/docs/grammar.txt b/docs/grammar.txt index ce3fd3ad..e700c946 100644 --- a/docs/grammar.txt +++ b/docs/grammar.txt @@ -27,14 +27,19 @@ ModifierInvocation = Identifier ( '(' ExpressionList? ')' )? FunctionDefinition = 'function' Identifier? ParameterList ( ModifierInvocation | StateMutability | 'external' | 'public' | 'internal' | 'private' )* ( 'returns' ParameterList )? ( ';' | Block ) -EventDefinition = 'event' Identifier IndexedParameterList 'anonymous'? ';' +EventDefinition = 'event' Identifier EventParameterList 'anonymous'? ';' EnumValue = Identifier EnumDefinition = 'enum' Identifier '{' EnumValue? (',' EnumValue)* '}' -IndexedParameterList = '(' ( TypeName 'indexed'? Identifier? (',' TypeName 'indexed'? Identifier?)* )? ')' -ParameterList = '(' ( TypeName Identifier? (',' TypeName Identifier?)* )? ')' -TypeNameList = '(' ( TypeName (',' TypeName )* )? ')' +ParameterList = '(' ( Parameter (',' Parameter)* )? ')' +Parameter = TypeName StorageLocation? Identifier? + +EventParameterList = '(' ( EventParameter (',' EventParameter )* )? ')' +EventParameter = TypeName 'indexed'? Identifier? + +FunctionTypeParameterList = '(' ( FunctionTypeParameter (',' FunctionTypeParameter )* )? ')' +FunctionTypeParameter = TypeName StorageLocation? // semantic restriction: mappings and structs (recursively) containing mappings // are not allowed in argument lists @@ -50,8 +55,8 @@ UserDefinedTypeName = Identifier ( '.' Identifier )* Mapping = 'mapping' '(' ElementaryTypeName '=>' TypeName ')' ArrayTypeName = TypeName '[' Expression? ']' -FunctionTypeName = 'function' TypeNameList ( 'internal' | 'external' | StateMutability )* - ( 'returns' TypeNameList )? +FunctionTypeName = 'function' FunctionTypeParameterList ( 'internal' | 'external' | StateMutability )* + ( 'returns' FunctionTypeParameterList )? StorageLocation = 'memory' | 'storage' StateMutability = 'pure' | 'constant' | 'view' | 'payable' diff --git a/docs/julia.rst b/docs/julia.rst index 309e6b36..9e961a9d 100644 --- a/docs/julia.rst +++ b/docs/julia.rst @@ -14,6 +14,13 @@ It can already be used for "inline assembly" inside Solidity and future versions of the Solidity compiler will even use JULIA as intermediate language. It should also be easy to build high-level optimizer stages for JULIA. +.. note:: + + Note that the flavour used for "inline assembly" does not have types + (everything is ``u256``) and the built-in functions are identical + to the EVM opcodes. Please resort to the inline assembly documentation + for details. + The core components of JULIA are functions, blocks, variables, literals, for-loops, if-statements, switch-statements, expressions and assignments to variables. |