Skip to content

Use fixed-width types in SQLite::Header - #582

Merged
SRombauts merged 1 commit into
masterfrom
abi-header-fixed-width-types
Sep 22, 2026
Merged

SRombauts merged 1 commit into
masterfrom
abi-header-fixed-width-types

Conversation

@SRombauts

@SRombauts SRombauts commented Sep 22, 2026

Copy link
Copy Markdown
Owner

Summary

  • use std::uint8_t and std::uint32_t for SQLite::Header fields
  • replace the 3.x ABI guard with compile-time checks for all fixed-width public field types
  • document the intentional 4.0 ABI change

Rationale

This reintroduces the public type change from #558 that #575 intentionally deferred to preserve the 3.4.0 ABI.

SQLite database-header fields have defined byte widths. Using fixed-width integer types makes those widths independent of the platform data model, notably avoiding 64-bit unsigned long fields on LP64 systems. The existing UB-free big-endian parsing remains unchanged.

Testing

The existing Database.getHeaderInfo test covers the parsed values. Compile-time assertions cover every public Header field type.

The same code change previously passed the full CI matrix. The branch has now been rebased onto master after the shared-library ABI generation was bumped from 0 to 1 in both CMake and Meson, and CI is revalidating that final state.

@SRombauts SRombauts self-assigned this Sep 22, 2026
@coveralls

coveralls commented Sep 22, 2026

Copy link
Copy Markdown

Coverage Status

coverage: 99.715%. remained the same — abi-header-fixed-width-types into master

@SRombauts
SRombauts force-pushed the abi-header-fixed-width-types branch 2 times, most recently from d23f662 to 7b23aae Compare September 22, 2026 15:34
@SRombauts
SRombauts force-pushed the abi-header-fixed-width-types branch 2 times, most recently from 69b48c4 to b7769b9 Compare September 22, 2026 15:54
@SRombauts
SRombauts merged commit bb1ff28 into master Sep 22, 2026
60 checks passed
@SRombauts
SRombauts deleted the abi-header-fixed-width-types branch September 22, 2026 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants