diff options
author | Daniel Kirchner <daniel@ekpyron.org> | 2018-05-08 19:08:52 +0800 |
---|---|---|
committer | Alex Beregszaszi <alex@rtfs.hu> | 2018-05-09 21:07:47 +0800 |
commit | bc47265b3f6d5c15b5c57c3edc927448a8599096 (patch) | |
tree | 649d1225fa558a1ee13c8c325fd510082d0e45b0 /test/libsolidity/syntaxTests/fallback | |
parent | 5cbe3e1a50f4aed7d07b7c45f115ac97df2c885a (diff) | |
download | dexon-solidity-bc47265b3f6d5c15b5c57c3edc927448a8599096.tar.gz dexon-solidity-bc47265b3f6d5c15b5c57c3edc927448a8599096.tar.zst dexon-solidity-bc47265b3f6d5c15b5c57c3edc927448a8599096.zip |
Replace constant with view in the tests.
Diffstat (limited to 'test/libsolidity/syntaxTests/fallback')
-rw-r--r-- | test/libsolidity/syntaxTests/fallback/pure_modifier.sol | 6 | ||||
-rw-r--r-- | test/libsolidity/syntaxTests/fallback/view_modifier.sol | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/test/libsolidity/syntaxTests/fallback/pure_modifier.sol b/test/libsolidity/syntaxTests/fallback/pure_modifier.sol new file mode 100644 index 00000000..20d5b0ac --- /dev/null +++ b/test/libsolidity/syntaxTests/fallback/pure_modifier.sol @@ -0,0 +1,6 @@ +contract C { + uint x; + function() pure { x = 2; } +} +// ---- +// TypeError: (29-55): Fallback function must be payable or non-payable, but is "pure". diff --git a/test/libsolidity/syntaxTests/fallback/view_modifier.sol b/test/libsolidity/syntaxTests/fallback/view_modifier.sol new file mode 100644 index 00000000..44c5d204 --- /dev/null +++ b/test/libsolidity/syntaxTests/fallback/view_modifier.sol @@ -0,0 +1,6 @@ +contract C { + uint x; + function() view { x = 2; } +} +// ---- +// TypeError: (29-55): Fallback function must be payable or non-payable, but is "view". |