mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-09 08:33:28 +02:00
Move the duplicated ThrowIfTDZ emission logic from three places in ASTCodegen.cpp into a single Generator::emit_tdz_check_if_needed() helper. This handles both argument TDZ (which requires a Mov to empty first) and lexically-declared variable TDZ uniformly. This avoids emitting some unnecessary ThrowIfTDZ instructions.
22 KiB
22 KiB