- Add warn() for non-fatal parse errors (like Zig's Parse.warn)
- Implement finishAssignDestructureExpr for destructuring assignments
- Use parseBlockExpr instead of parseBlock in for/while statement bodies
- Use parseSingleAssignExpr in switch prongs
- Enable x86_64/CodeGen.zig corpus entry
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The @unionInit handler in builtinCallMultiArg was propagating the parent's
result info context (e.g. RI_CTX_RETURN) to the init value expression.
Upstream Zig creates a fresh ResultInfo with .ctx = .none. This caused
call flags mismatch (pop_error_return_trace) in return expressions.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
rlBuiltinCall was always returning false (not consuming result location).
The Zig reference marks @frameAddress as consuming the RL (workaround for
llvm/llvm-project#68409), which affects declaration codegen path (pointer
vs value based). Match the upstream behavior.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The AST_NODE_CONTAINER_FIELD case in structDeclInner had an incorrect guard
`if (nd.rhs != 0)` before reading align/value from extra_data. Since rhs is
an extra_data index (not a node), 0 is a valid index. Removing the guard
fixes 3-5 missing instructions in files where the first extra_data entry
happens to be a container_field's align+value.
Also fix clang-format: addBuiltinValue arg wrapping, for-loop semicolons.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Upgrade decimal_float_fits_f64() to use 128-bit integer arithmetic for the
algebraic round-trip test, handling mantissas up to ~38 significant digits.
This fixes float128-vs-float tag mismatches for values that fit in 128-bit
mantissa but overflow 64-bit.
Newly enabled: gpu, memmove, mulf3, udivmodei4, udivmod, scalar, ff,
p256_64, p256_scalar_64, p384_64, p384_scalar_64, secp256k1_64,
secp256k1_scalar_64, sha2, sha3, Decompress, testing, log10, log2, log,
rem_pio2f, rem_pio2_large, rem_pio2.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
decimal_float_fits_f64() incorrectly returned true when a non-zero mantissa
(that had overflowed uint64_t) was converted to 0.0 by strtod. These values
do not fit in f64 and need f128 representation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Fix strtod underflow/overflow edge cases in decimal_float_fits_f64.
Enables 707 files across lib/std/, lib/compiler_rt/, src/, and more.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Define named constants for the three categories of optional sentinel
values, matching their Zig counterparts (?TokenIndex null,
?Node.Index null, Zir.Inst.OptionalIndex .none). This makes intent
explicit and prevents sentinel/zero confusion bugs like the one
fixed in 455967af.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>