aboutsummaryrefslogtreecommitdiffstats
path: root/test/libsolidity/syntaxTests
diff options
context:
space:
mode:
authorDaniel Kirchner <daniel@ekpyron.org>2018-11-08 18:22:57 +0800
committerchriseth <chris@ethereum.org>2018-11-26 23:31:46 +0800
commit30e6f8d3fb9a16dc1e07367c9010aabe3577e2f1 (patch)
tree0d250ea55121d0a3f9805d99a8b20d030dd60a1e /test/libsolidity/syntaxTests
parentf6d8810103c762d1f5a41bf1c29d33b771cfed50 (diff)
downloaddexon-solidity-30e6f8d3fb9a16dc1e07367c9010aabe3577e2f1.tar.gz
dexon-solidity-30e6f8d3fb9a16dc1e07367c9010aabe3577e2f1.tar.zst
dexon-solidity-30e6f8d3fb9a16dc1e07367c9010aabe3577e2f1.zip
Allow mapping arguments for public and external library functions.
Diffstat (limited to 'test/libsolidity/syntaxTests')
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/library_argument_external.sol1
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/library_argument_public.sol1
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/library_return_external.sol3
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/library_return_public.sol3
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_external.sol4
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_public.sol3
-rw-r--r--test/libsolidity/syntaxTests/types/mapping/mapping_return_public_memory.sol3
7 files changed, 4 insertions, 14 deletions
diff --git a/test/libsolidity/syntaxTests/types/mapping/library_argument_external.sol b/test/libsolidity/syntaxTests/types/mapping/library_argument_external.sol
index 1098008d..ebd05d86 100644
--- a/test/libsolidity/syntaxTests/types/mapping/library_argument_external.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/library_argument_external.sol
@@ -3,4 +3,3 @@ library L {
}
}
// ----
-// TypeError: (27-56): Type is required to live outside storage.
diff --git a/test/libsolidity/syntaxTests/types/mapping/library_argument_public.sol b/test/libsolidity/syntaxTests/types/mapping/library_argument_public.sol
index dedd4f68..36e833b7 100644
--- a/test/libsolidity/syntaxTests/types/mapping/library_argument_public.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/library_argument_public.sol
@@ -3,4 +3,3 @@ library L {
}
}
// ----
-// TypeError: (27-56): Type is required to live outside storage.
diff --git a/test/libsolidity/syntaxTests/types/mapping/library_return_external.sol b/test/libsolidity/syntaxTests/types/mapping/library_return_external.sol
index 1e756819..6c145801 100644
--- a/test/libsolidity/syntaxTests/types/mapping/library_return_external.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/library_return_external.sol
@@ -5,6 +5,3 @@ library L
}
}
// ----
-// TypeError: (27-58): Type is required to live outside storage.
-// TypeError: (60-91): Type is required to live outside storage.
-// TypeError: (123-152): Type is required to live outside storage.
diff --git a/test/libsolidity/syntaxTests/types/mapping/library_return_public.sol b/test/libsolidity/syntaxTests/types/mapping/library_return_public.sol
index 357751a0..a98458cd 100644
--- a/test/libsolidity/syntaxTests/types/mapping/library_return_public.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/library_return_public.sol
@@ -5,6 +5,3 @@ library L
}
}
// ----
-// TypeError: (27-58): Type is required to live outside storage.
-// TypeError: (60-91): Type is required to live outside storage.
-// TypeError: (121-150): Type is required to live outside storage.
diff --git a/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_external.sol b/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_external.sol
index c050f8e9..fa3757fa 100644
--- a/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_external.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_external.sol
@@ -2,5 +2,5 @@ contract c {
function f1(mapping(uint => uint) calldata) pure external returns (mapping(uint => uint) memory) {}
}
// ----
-// TypeError: (29-59): Type is required to live outside storage.
-// TypeError: (29-59): Internal or recursive type is not allowed for public or external functions.
+// TypeError: (29-59): Mapping types for parameters or return variables can only be used in internal or library functions.
+// TypeError: (84-112): Mapping types for parameters or return variables can only be used in internal or library functions.
diff --git a/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_public.sol b/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_public.sol
index b63868b8..8c73b5ae 100644
--- a/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_public.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/mapping_data_location_function_param_public.sol
@@ -2,5 +2,4 @@ contract c {
function f3(mapping(uint => uint) memory) view public {}
}
// ----
-// TypeError: (29-57): Type is required to live outside storage.
-// TypeError: (29-57): Internal or recursive type is not allowed for public or external functions.
+// TypeError: (29-57): Mapping types for parameters or return variables can only be used in internal or library functions.
diff --git a/test/libsolidity/syntaxTests/types/mapping/mapping_return_public_memory.sol b/test/libsolidity/syntaxTests/types/mapping/mapping_return_public_memory.sol
index 35c3abc9..7378324a 100644
--- a/test/libsolidity/syntaxTests/types/mapping/mapping_return_public_memory.sol
+++ b/test/libsolidity/syntaxTests/types/mapping/mapping_return_public_memory.sol
@@ -3,5 +3,4 @@ contract C {
}
}
// ----
-// TypeError: (51-79): Type is required to live outside storage.
-// TypeError: (51-79): Internal or recursive type is not allowed for public or external functions.
+// TypeError: (51-79): Mapping types for parameters or return variables can only be used in internal or library functions.