mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-30 11:37:16 +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