Fix build errors with LLVM 23 - #13673
Open
masaori335 wants to merge 2 commits into
Open
masaori335 wants to merge 2 commits into
masaori335 wants to merge 2 commits into
Conversation
LLVM 23 flips libc++'s transitive-include compatibility block from opt-out to opt-in (_LIBCPP_KEEP_TRANSITIVE_INCLUDES_LLVM23), so <algorithm> and <string> no longer drag in <iterator> and <cstdlib>. Include them where the symbols are actually used rather than relying on the old default.
The const char (&)[N] overload of matches_bracketed_int_range can never be selected: RecordElement::regex is a const char *, so the string_view overload always wins. RecMessageRegisterRecvCb has had no callers since traffic_manager was removed, leaving its cookie global set but never read.
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No unresolved review issues remain, and the changes address LLVM 23 compatibility warnings and errors.
Pull request overview
Fixes LLVM 23.1/macOS build errors by adding required standard-library headers and removing unused code.
Changes:
- Adds direct
<algorithm>,<iterator>, and<cstdlib>includes. - Removes unused record-message callbacks and template code.
File summaries
| File | Summary |
|---|---|
src/traffic_cache_tool/CacheTool.cc |
Adds <algorithm>. |
src/records/RecordsConfig.cc |
Removes unused template overload. |
src/records/RecMessage.cc |
Removes unused callback state and function. |
src/records/P_RecMessage.h |
Removes callback declaration. |
src/records/P_RecDefs.h |
Removes callback type alias. |
src/mgmt/config/ReloadCoordinator.cc |
Adds <iterator>. |
plugins/multiplexer/ats-multiplexer.cc |
Adds <iterator>. |
plugins/experimental/inliner/png.h |
Adds <iterator>. |
plugins/experimental/inliner/cache-handler.h |
Adds <iterator>. |
plugins/experimental/cookie_remap/cookiejar.cc |
Adds <cstdlib>. |
lib/swoc/unit_tests/test_TextView.cc |
Adds <iterator>. |
Review details
- Files reviewed: 11/11 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
I faced some compile errors with LLVM-23.1 on macOS.
-Wunused-templateand-Wunused-but-set-globalare enabled by default