mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
test: Adapts InlineAssembly test case for jump instruction (which doesn't "exist" in strict assembly).
This commit is contained in:
parent
f45c3124f8
commit
30a99e0df4
@ -1,5 +1,5 @@
|
||||
Warning: Yul and its optimizer are still experimental. Please use the output with care.
|
||||
Error: Jump instructions and labels are low-level EVM features that can lead to incorrect stack access. Because of that they are disallowed in strict assembly. Use functions, "switch", "if" or "for" statements instead.
|
||||
Error: Function not found.
|
||||
--> strict_asm_jump/input.sol:1:3:
|
||||
|
|
||||
1 | { jump(1) }
|
||||
|
@ -742,8 +742,8 @@ BOOST_AUTO_TEST_CASE(shift_constantinople_warning)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(jump_error)
|
||||
{
|
||||
CHECK_PARSE_WARNING("{ jump(44) }", SyntaxError, "Jump instructions and labels are low-level EVM features");
|
||||
CHECK_PARSE_WARNING("{ jumpi(44, 2) }", SyntaxError, "Jump instructions and labels are low-level EVM features");
|
||||
CHECK_PARSE_WARNING("{ jump(44) }", DeclarationError, "Function not found.");
|
||||
CHECK_PARSE_WARNING("{ jumpi(44, 2) }", DeclarationError, "Function not found.");
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_SUITE_END()
|
||||
|
Loading…
Reference in New Issue
Block a user