Skip to content

Commit

Permalink
eof: Hide rjumps in yul
Browse files Browse the repository at this point in the history
  • Loading branch information
rodiazet committed Nov 30, 2024
1 parent b4ecc58 commit 120e344
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libyul/backends/evm/EVMDialect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,8 @@ std::vector<std::optional<BuiltinFunctionForEVM>> createBuiltins(langutil::EVMVe
opcode != evmasm::Instruction::DATALOADN &&
opcode != evmasm::Instruction::EOFCREATE &&
opcode != evmasm::Instruction::RETURNCONTRACT &&
opcode != evmasm::Instruction::RJUMP &&
opcode != evmasm::Instruction::RJUMPI &&
opcode != evmasm::Instruction::CALLF &&
opcode != evmasm::Instruction::JUMPF &&
opcode != evmasm::Instruction::RETF &&
Expand Down
11 changes: 11 additions & 0 deletions test/libyul/yulSyntaxTests/eof/rjump_rjumpi.yul
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
object "a" {
code {
rjump()
rjumpi()
}
}
// ====
// bytecodeFormat: legacy,>=EOFv1
// ----
// DeclarationError 4619: (32-37): Function "rjump" not found.
// DeclarationError 4619: (48-54): Function "rjumpi" not found.

0 comments on commit 120e344

Please sign in to comment.