Skip to content

v0.4.0

@ehsanmok ehsanmok tagged this 14 Sep 03:36
`loads(bytes: Span[UInt8, _])` handed its argument straight to
`String(unsafe_from_utf8=...)`. That constructor takes well-formedness
as a promise, so ill-formed bytes are undefined behaviour and trip an
assertion under `-D ASSERT=all`. The documentation even said the bytes
need not be valid, on the reasoning that the parser would reject them
later, which is true only when assertions are off.

The overload now validates first and raises, which reaches the same
outcome earlier. AddressSanitizer found this on its first CI run, in
the test written to pin the behaviour.

Two CI jobs added in the same session cannot work on a GitHub runner
and are corrected here. Compiling the GPU sources needs a real
accelerator, not merely `max-core`: the kernels are instantiated for a
concrete architecture, and without a device the compiler stops with
"Unknown GPU architecture detected". The `check-gpu-build` step is
removed from the compile-only job, `tools/check_warnings.sh` probes for
an accelerator and skips those seven files when there is none, and the
task comment claiming a device was unnecessary is corrected.

Co-Authored-By: <noreply@anthropic.com>
Assets 2
Loading