diff options
-rw-r--r-- | subx/034discourage_raw_hex.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/subx/034discourage_raw_hex.cc b/subx/034discourage_raw_hex.cc index e5393bab..22f45b1d 100644 --- a/subx/034discourage_raw_hex.cc +++ b/subx/034discourage_raw_hex.cc @@ -14,8 +14,14 @@ void warn_on_raw_jumps(/*const*/ program& p) { for (int i = 0; i < SIZE(code.lines); ++i) { line& inst = code.lines.at(i); if (all_hex_bytes(inst) && has_operands(inst)) { - warn << "'" << to_string(inst) << "': using raw hex is not recommended.\n" << end(); + warn << "'" << to_string(inst) << "': using raw hex is not recommended\n" << end(); break; } } } + +:(scenario warn_on_hex_bytes_without_operands) +% Hide_warnings = true; +== 0x1 +bb 2a 00 00 00 # copy 0x2a (42) to EBX ++warn: 'bb 2a 00 00 00': using raw hex is not recommended |