aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/libjulia/Parser.cpp2
-rw-r--r--test/libsolidity/SolidityEndToEndTest.cpp18
2 files changed, 19 insertions, 1 deletions
diff --git a/test/libjulia/Parser.cpp b/test/libjulia/Parser.cpp
index f6db828a..dd6f3d94 100644
--- a/test/libjulia/Parser.cpp
+++ b/test/libjulia/Parser.cpp
@@ -133,7 +133,7 @@ BOOST_AUTO_TEST_CASE(vardecl_bool)
BOOST_AUTO_TEST_CASE(vardecl_empty)
{
- BOOST_CHECK(successParse("{ let x }"));
+ BOOST_CHECK(successParse("{ let x:u256 }"));
}
BOOST_AUTO_TEST_CASE(assignment)
diff --git a/test/libsolidity/SolidityEndToEndTest.cpp b/test/libsolidity/SolidityEndToEndTest.cpp
index 7b130082..94d3e168 100644
--- a/test/libsolidity/SolidityEndToEndTest.cpp
+++ b/test/libsolidity/SolidityEndToEndTest.cpp
@@ -9723,6 +9723,24 @@ BOOST_AUTO_TEST_CASE(multi_modifiers)
BOOST_CHECK(callContractFunction("x()") == encodeArgs(u256(12)));
}
+BOOST_AUTO_TEST_CASE(inlineasm_empty_let)
+{
+ char const* sourceCode = R"(
+ contract C {
+ function f() returns (uint a, uint b) {
+ assembly {
+ let x
+ let y, z
+ a := x
+ b := z
+ }
+ }
+ }
+ )";
+ compileAndRun(sourceCode, 0, "C");
+ BOOST_CHECK(callContractFunction("f()") == encodeArgs(u256(0), u256(0)));
+}
+
BOOST_AUTO_TEST_SUITE_END()
}