Issue Summary
WiredTiger fails to compile with AppleClang 21 when strict Clang warnings are enabled because generated/public headers declare internal struct tags beginning with double underscores, such as struct __wt_connection. AppleClang 21 diagnoses these names under -Wreserved-identifier, and WiredTiger promotes the warning to an error.
error: identifier '__wt_connection' is reserved because it starts with '__' [-Werror,-Wreserved-identifier]
Context
- The failure occurs in the generated include/wiredtiger.h while compiling normal WiredTiger C sources, including src/block/block_addr.c.
- The strict Clang configuration enables -Weverything and -Werror.
- The existing -Wno-reserved-id-macro suppression only covers reserved macro names; it does not suppress -Wreserved-identifier.
- The failure reproduces independently with Python/SWIG disabled, so it is not a SWIG-specific failure.
Proposed Solution
- Add an intentional -Wno-reserved-identifier suppression for the affected Clang builds, or otherwise scope the suppression to the generated/public WiredTiger header.
- Evaluate whether the suppression should apply globally to WiredTiger C targets or only to code that includes the generated API header.
- Avoid renaming all existing _wt* tags unless the ABI and generated-header impact has been evaluated.
Acceptance Criteria
- WiredTiger builds successfully with AppleClang 21 using the strict warning configuration.
- The intentional suppression does not hide unrelated diagnostics.
- Existing Clang and non-Clang warning policies remain unchanged.
- A macOS/AppleClang build check covers the affected configuration.