Repository navigation
An asserted reference (<Reference<i32>>ref) reinterprets again (release blocker from #775) - #776
Merged
Merged
Conversation
…interprets again #775 made a reference to a number cast to one laid out otherwise an error, in cast(), which explicit assertions reach too. The default library's HashHelpers.hashCodeGeneral reads a number key's bits through `<Reference<i32>>Ref(key)`, so every Map/Set with number keys failed to compile (map_get_number, map_negative_keys, map_size_delete under every model). Found by the pre-release default-library check before tagging. An assertion between two reference types is a plain reinterpreting cast again, as before #775; the layout check stays for implicit conversions (a call's argument, an assignment). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Release blocker for v0.0-pre-alpha116, found by the pre-release default-library check (debug + release default library built the way
create-release.ymlbuilds it, thentests.ps1for every model).#775 made a reference to a number cast to a reference to a number laid out otherwise an error (TSLANG 26). The check sat in
cast(), which explicit assertions reach too. The default library'sHashHelpers.hashCodeGeneralreads a number key's bits through<Reference<i32>>Ref(key), so everyMap/Setwithnumberkeys stopped compiling.map_get_number,map_negative_keysandmap_size_deletefailed under gc, rc, none and own.An assertion between two reference types (
<Reference<i32>>ref,ref as Reference<i32>) is again a plain reinterpreting cast, as before #775. The layout check stays for implicit conversions: a call's argument (the TSLANG 26 case) or an assignment.Tests
00tslang_issues_24_26: reads 1.5's halves through<Reference<i32>>andas Reference<i32>;ref_element_layout_errorstill errors.tests.ps1(DL main 46113d8): gc 187/187; rc, none and own 186/187 plus the gc-only weakref skip. Release and debug, compile and jit.ctest -C Release: 6670 tests, all passing.🤖 Generated with Claude Code