aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/syntaxTests/fallback
diff options
context:
space:
mode:
authorDaniel Kirchner <daniel@ekpyron.org>2018-05-08 19:08:52 +0800
committerAlex Beregszaszi <alex@rtfs.hu>2018-05-09 21:07:47 +0800
commitbc47265b3f6d5c15b5c57c3edc927448a8599096 (patch)
tree649d1225fa558a1ee13c8c325fd510082d0e45b0 /test/libsolidity/syntaxTests/fallback
parent5cbe3e1a50f4aed7d07b7c45f115ac97df2c885a (diff)
downloaddexon-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.sol6
-rw-r--r--test/libsolidity/syntaxTests/fallback/view_modifier.sol6
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".