Repository navigation
refactor: Fix callback merging and moved type paths - #2038
Open
thedataking wants to merge 2 commits into
Open
thedataking wants to merge 2 commits into
thedataking wants to merge 2 commits into
Conversation
ahomescu
reviewed
Oct 20, 2026
ahomescu
requested changes
Oct 20, 2026
ahomescu
reviewed
Oct 20, 2026
ahomescu
requested changes
Oct 20, 2026
Contributor
|
As a general comment, this could have been 3 or 4 PRs in a stack. |
thedataking
force-pushed
the
issue-2037
branch
from
November 4, 2026 18:53
df4154d to
1001371
Compare
ahomescu
requested changes
Nov 4, 2026
thedataking
force-pushed
the
issue-2037
branch
from
November 5, 2026 10:53
1001371 to
816834f
Compare
SQLite extension API tables combine translation-unit-local types with bound VaList lifetimes. Compare these callbacks modulo binder names while retaining layout, bitfield, generic argument, and signature distinctions so equivalent tables can share one definition safely. Qualify references to unmoved source-local items before moving header declarations, since their imports may remain with inline functions or be subsumed by other declarations.
Strict structural array comparison protects ADT layouts, but incomplete C extern arrays still need to match complete definitions. Avoid generating an invalid whole-array cast for this case without weakening comparisons of struct fields or array elements. When canonicalize_externs replaces a complete extern array with an incomplete one, access it through a pointer to the complete array type so indexing and length are preserved.
thedataking
force-pushed
the
issue-2037
branch
from
November 5, 2026 17:07
816834f to
32b5fc1
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.
reorganize_definitionssplits equivalent SQLite extension API tables because callbacks combining translation-unit-local types withVaListhave bound lifetimes. Compare those function-pointer signatures modulo bound-variable names while preserving lifetime relationships, generic arguments, safety, ABI, representation, bitfield metadata, and array lengths.Moved header declarations can also lose the imports that named source-local types. Qualify those references from their original resolved definitions before moving the declarations, preserving generic arguments.
Together these changes let SQLite's CLI shell and bundled extensions share their API table and keep moved declarations well-typed.
Fixes #2037.