Repository navigation
Make the ThreadScan definition in thw3.c match its declaration - #318
Open
defmacro-jam wants to merge 1 commit into
Open
defmacro-jam wants to merge 1 commit into
defmacro-jam wants to merge 1 commit into
Conversation
code/th.h declares ThreadScan's stackCold parameter as void *, as do the definitions in than.c, thix.c and thxc.c, but thw3.c defined it as Word *. Clang rejects the mismatch as conflicting types when building w3i6mv with clang-cl. The body assigns stackCold to a Word * and passes it to StackScan, whose parameter is void *, so no other change is needed. Fixes GitHub issue Ravenbrook#317 <Ravenbrook#317>.
defmacro-jam
force-pushed
the
branch/2026-10-19/thw3-threadscan-signature
branch
from
October 20, 2026 00:42
11a35c7 to
3957bbe
Compare
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.
Fixes #317.
code/th.h:71declaresThreadScan's third parameter asvoid *stackCold, as do the definitions inthan.c,thix.candthxc.c, butcode/thw3.c:262defined it asWord *stackCold. Clang (22.1.8, asclang-cltargetingx86_64-pc-windows-msvc) rejects the mismatch as conflicting types when buildingmps.cforw3i6mv.The change is the parameter type only. The function body assigns
stackColdto aWord *and passes it toStackScan, whose parameter isvoid *, so nothing else changes. The line keeps its length, so the continuation line's alignment is unchanged.Tested by building
mps.cwith this change under clang-cl 22.1.8 on GitLab's hosted Windows runner: the conflicting-types error is gone. Not tested with Microsoftcl.