diff options
author | chriseth <chris@ethereum.org> | 2018-04-11 23:58:53 +0800 |
---|---|---|
committer | chriseth <chris@ethereum.org> | 2018-04-12 04:00:21 +0800 |
commit | 52f68d3b63d65c31215e683899b96b27e2e24ee1 (patch) | |
tree | 6bf9edb6098ba51a796c1131c1250e308db53501 /test/libsolidity | |
parent | 4e1ea0866d889daa1144d7c4d89b16cd03cf7dc2 (diff) | |
download | dexon-solidity-52f68d3b63d65c31215e683899b96b27e2e24ee1.tar.gz dexon-solidity-52f68d3b63d65c31215e683899b96b27e2e24ee1.tar.zst dexon-solidity-52f68d3b63d65c31215e683899b96b27e2e24ee1.zip |
Update expectations.
Diffstat (limited to 'test/libsolidity')
10 files changed, 18 insertions, 17 deletions
diff --git a/test/libsolidity/syntaxTests/functionTypes/function_type_variable_external_internal.sol b/test/libsolidity/syntaxTests/functionTypes/function_type_variable_external_internal.sol index b42f6908..f0240472 100644 --- a/test/libsolidity/syntaxTests/functionTypes/function_type_variable_external_internal.sol +++ b/test/libsolidity/syntaxTests/functionTypes/function_type_variable_external_internal.sol @@ -1,6 +1,6 @@ contract test { - function fa(bytes memory) { } + function fa(bytes memory) public { } function(bytes memory) external internal a = fa; } // ---- -// TypeError: (99-101): Type function (bytes memory) is not implicitly convertible to expected type function (bytes memory) external. +// TypeError: (106-108): Type function (bytes memory) is not implicitly convertible to expected type function (bytes memory) external. diff --git a/test/libsolidity/syntaxTests/modifiers/base_constructor_double_invocation.sol b/test/libsolidity/syntaxTests/modifiers/base_constructor_double_invocation.sol index a2a82521..bdbab5d8 100644 --- a/test/libsolidity/syntaxTests/modifiers/base_constructor_double_invocation.sol +++ b/test/libsolidity/syntaxTests/modifiers/base_constructor_double_invocation.sol @@ -1,6 +1,7 @@ -contract C { function C(uint a) public {} } +contract C { constructor(uint a) public {} } contract B is C { - function B() C(2) C(2) public {} + constructor() C(2) C(2) public {} } // ---- -// DeclarationError: Base constructor already provided. +// Warning: (81-85): Base constructor arguments given twice. +// DeclarationError: (86-90): Base constructor already provided. diff --git a/test/libsolidity/syntaxTests/modifiers/constructor_call_invalid_arg_count.sol b/test/libsolidity/syntaxTests/modifiers/constructor_call_invalid_arg_count.sol index fac9b319..4a2b5c4a 100644 --- a/test/libsolidity/syntaxTests/modifiers/constructor_call_invalid_arg_count.sol +++ b/test/libsolidity/syntaxTests/modifiers/constructor_call_invalid_arg_count.sol @@ -1,9 +1,9 @@ // This caused a segfault in an earlier version contract C { - function C() public {} + constructor() public {} } contract D is C { - function D() C(5) public {} + constructor() C(5) public {} } // ---- -// TypeError: Wrong argument count for modifier invocation: 1 arguments given but expected 0. +// TypeError: (127-131): Wrong argument count for modifier invocation: 1 arguments given but expected 0. diff --git a/test/libsolidity/syntaxTests/modifiers/function_modifier_invocation_local_variables050.sol b/test/libsolidity/syntaxTests/modifiers/function_modifier_invocation_local_variables050.sol index 52439f2b..c19ccf2c 100644 --- a/test/libsolidity/syntaxTests/modifiers/function_modifier_invocation_local_variables050.sol +++ b/test/libsolidity/syntaxTests/modifiers/function_modifier_invocation_local_variables050.sol @@ -4,4 +4,4 @@ contract B { modifier mod(uint a) { if (a > 0) _; } } // ---- -// DeclarationError: Undeclared identifier. +// DeclarationError: (64-65): Undeclared identifier. diff --git a/test/libsolidity/syntaxTests/modifiers/function_overrides_modifier.sol b/test/libsolidity/syntaxTests/modifiers/function_overrides_modifier.sol index 25485bec..a64c2790 100644 --- a/test/libsolidity/syntaxTests/modifiers/function_overrides_modifier.sol +++ b/test/libsolidity/syntaxTests/modifiers/function_overrides_modifier.sol @@ -1,5 +1,5 @@ contract A { function mod(uint a) public { } } contract B is A { modifier mod(uint a) { _; } } // ---- -// DeclarationError: Identifier already declared. -// TypeError: Override changes function to modifier. +// DeclarationError: (65-92): Identifier already declared. +// TypeError: (65-92): Override changes function to modifier. diff --git a/test/libsolidity/syntaxTests/modifiers/illegal_modifier_override.sol b/test/libsolidity/syntaxTests/modifiers/illegal_modifier_override.sol index f77a529b..958be686 100644 --- a/test/libsolidity/syntaxTests/modifiers/illegal_modifier_override.sol +++ b/test/libsolidity/syntaxTests/modifiers/illegal_modifier_override.sol @@ -1,4 +1,4 @@ contract A { modifier mod(uint a) { _; } } contract B is A { modifier mod(uint8 a) { _; } } // ---- -// TypeError: Override changes modifier signature. +// TypeError: (61-89): Override changes modifier signature. diff --git a/test/libsolidity/syntaxTests/modifiers/invalid_function_modifier_type.sol b/test/libsolidity/syntaxTests/modifiers/invalid_function_modifier_type.sol index 8d7d1f9f..c1e3108b 100644 --- a/test/libsolidity/syntaxTests/modifiers/invalid_function_modifier_type.sol +++ b/test/libsolidity/syntaxTests/modifiers/invalid_function_modifier_type.sol @@ -3,4 +3,4 @@ contract B { modifier mod1(uint a) { if (a > 0) _; } } // ---- -// TypeError: Invalid type for argument in modifier invocation. Invalid implicit conversion from bool to uint256 requested. +// TypeError: (35-39): Invalid type for argument in modifier invocation. Invalid implicit conversion from bool to uint256 requested. diff --git a/test/libsolidity/syntaxTests/modifiers/modifier_overrides_function.sol b/test/libsolidity/syntaxTests/modifiers/modifier_overrides_function.sol index ebf36a0d..a43646c3 100644 --- a/test/libsolidity/syntaxTests/modifiers/modifier_overrides_function.sol +++ b/test/libsolidity/syntaxTests/modifiers/modifier_overrides_function.sol @@ -1,5 +1,5 @@ contract A { modifier mod(uint a) { _; } } contract B is A { function mod(uint a) public { } } // ---- -// DeclarationError: Identifier already declared. -// TypeError: Override changes modifier to function. +// DeclarationError: (61-92): Identifier already declared. +// TypeError: (13-40): Override changes modifier to function. diff --git a/test/libsolidity/syntaxTests/modifiers/modifier_returns_value.sol b/test/libsolidity/syntaxTests/modifiers/modifier_returns_value.sol index 0ae00b66..d22e836c 100644 --- a/test/libsolidity/syntaxTests/modifiers/modifier_returns_value.sol +++ b/test/libsolidity/syntaxTests/modifiers/modifier_returns_value.sol @@ -3,4 +3,4 @@ contract A { modifier mod(uint a) { _; return 7; } } // ---- -// TypeError: Return arguments not allowed. +// TypeError: (101-109): Return arguments not allowed. diff --git a/test/libsolidity/syntaxTests/modifiers/modifier_without_underscore.sol b/test/libsolidity/syntaxTests/modifiers/modifier_without_underscore.sol index ae44c4c7..6198d3c5 100644 --- a/test/libsolidity/syntaxTests/modifiers/modifier_without_underscore.sol +++ b/test/libsolidity/syntaxTests/modifiers/modifier_without_underscore.sol @@ -2,4 +2,4 @@ contract test { modifier m() {} } // ---- -// SyntaxError: Modifier body does not contain '_'. +// SyntaxError: (33-35): Modifier body does not contain '_'. |