Skip to content

Commit

Permalink
Fix "unrecognized YAML option" error if disassemble_all is provided…
Browse files Browse the repository at this point in the history
… via CLI and as a YAML option.
  • Loading branch information
AngheloAlf committed Jan 24, 2025
1 parent af668f0 commit 4fb7fee
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/splat/util/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -554,10 +554,10 @@ def parse_endianness() -> Literal["big", "little"]:
detect_redundant_function_end=p.parse_opt(
"detect_redundant_function_end", bool, True
),
# Command line argument takes precedence over yaml option
disassemble_all=(
disasm_all if disasm_all else p.parse_opt("disassemble_all", bool, False)
),
# Setting either option will produce a full disassembly,
# but we still have to check the yaml option first to avoid leaving option unparsed,
# because splat would complain about an unrecognized yaml option otherwise.
disassemble_all=p.parse_opt("disassemble_all", bool, False) or disasm_all,
global_vram_start=p.parse_optional_opt("global_vram_start", int),
global_vram_end=p.parse_optional_opt("global_vram_end", int),
use_gp_rel_macro_nonmatching=p.parse_opt(
Expand Down

0 comments on commit 4fb7fee

Please sign in to comment.