refactor: clean up uses of std::source_location - #6272
Conversation
There was a problem hiding this comment.
Pull request overview
This PR removes obsolete Clang version checks for std::source_location support. Since the minimum supported Clang version is now 16, the conditional includes for std::experimental::source_location (used for Clang < 15) are no longer necessary.
Changes:
- Removed conditional preprocessor directives checking for Clang < 15
- Replaced
using source_locationdeclarations with fully qualifiedstd::source_locationusage - Cleaned up includes by removing experimental source_location support
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/test/rpc/LedgerEntry_test.cpp | Removed Clang < 15 version checks and updated all source_location references to std::source_location |
| src/test/jtx/TestHelpers.h | Removed Clang < 15 version checks, updated source_location references to std::source_location, and reordered includes |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #6272 +/- ##
=========================================
- Coverage 79.4% 79.4% -0.0%
=========================================
Files 839 839
Lines 71619 71619
Branches 8231 8235 +4
=========================================
- Hits 56855 56850 -5
- Misses 14764 14769 +5 🚀 New features to boost your workflow:
|
Since the minimum Clang version we support is 16, the checks for version < 15 are no longer necessary. This change therefore removes the macros checking if the clang version is < 15 and simplifies uses of `std::source_location`.
High Level Overview of Change
This PR simplifies uses of
std::source_locationremove the macros checking if the clang version is < 15.No source code changes.
Context of Change
The minimum Clang version supported is 16, so the checks for version < 15 are no longer necessary.
Type of Change
.gitignore, formatting, dropping support for older tooling)API Impact
N/A
Test Plan
CI still compiles and passes on all versions.