diff options
author | Nicolai <NicolaiSoeborg@users.noreply.github.com> | 2016-07-20 08:26:33 +0800 |
---|---|---|
committer | Nicolai <NicolaiSoeborg@users.noreply.github.com> | 2016-07-20 08:26:33 +0800 |
commit | 6f7d8fb65b1a2351824aa2eb9b1bab6057840c3c (patch) | |
tree | c6bbf66d02e2d03698891aa7eed86ac90054bb5d /libsolidity/grammar.txt | |
parent | f003bdafa6ca623728befcbc8c8a22e8422dc9ec (diff) | |
download | dexon-solidity-6f7d8fb65b1a2351824aa2eb9b1bab6057840c3c.tar.gz dexon-solidity-6f7d8fb65b1a2351824aa2eb9b1bab6057840c3c.tar.zst dexon-solidity-6f7d8fb65b1a2351824aa2eb9b1bab6057840c3c.zip |
Allow function returns to be unnamed
Diffstat (limited to 'libsolidity/grammar.txt')
-rw-r--r-- | libsolidity/grammar.txt | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libsolidity/grammar.txt b/libsolidity/grammar.txt index a08a08fa..30fbd6b5 100644 --- a/libsolidity/grammar.txt +++ b/libsolidity/grammar.txt @@ -10,10 +10,12 @@ StateVariableDeclaration = TypeName ( 'public' | 'internal' | 'private' )? Ident ModifierDefinition = 'modifier' Identifier ParameterList? Block FunctionDefinition = 'function' Identifier ParameterList ( Identifier | 'constant' | 'external' | 'public' | 'internal' | 'private' )* - ( 'returns' ParameterList )? Block + ( 'returns' (ParameterList | TypeParameterList) )? Block EnumValue = Identifier EnumDefinition = 'enum' Identifier '{' EnumValue? (',' EnumValue)* '}' + +TypeParameterList = '(' ( TypeName (',' TypeName)* )? ')' ParameterList = '(' ( VariableDeclaration (',' VariableDeclaration)* )? ')' // semantic restriction: mappings and structs (recursively) containing mappings // are not allowed in argument lists |