From 525758a130941c6f1dfde8a0f884a550e7a7bb50 Mon Sep 17 00:00:00 2001 From: chriseth Date: Thu, 26 Jan 2017 13:40:40 +0100 Subject: Disallow assignment to non-identifiers. --- test/libsolidity/InlineAssembly.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/libsolidity') diff --git a/test/libsolidity/InlineAssembly.cpp b/test/libsolidity/InlineAssembly.cpp index 9ee84867..33721bbf 100644 --- a/test/libsolidity/InlineAssembly.cpp +++ b/test/libsolidity/InlineAssembly.cpp @@ -194,6 +194,12 @@ BOOST_AUTO_TEST_CASE(inline_assembly_shadowed_instruction_assignment) BOOST_CHECK(!successAssemble("{ 2 =: gas }")); } +BOOST_AUTO_TEST_CASE(inline_assembly_shadowed_instruction_functional_assignment) +{ + // Error message: "Cannot use instruction names for identifier names." + BOOST_CHECK(!successAssemble("{ gas := 2 }")); +} + BOOST_AUTO_TEST_SUITE_END() } -- cgit