Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: check for P2582R1 support #176

Merged
merged 1 commit into from
Feb 22, 2025

Conversation

StephanDollberg
Copy link
Member

Downstream scylladb#2446 to fix the gcc build

in a recent GCC packaging update in fedora, the maintainer backported a
patch [PR116276](https://gcc.gnu.org/pipermail/gcc-patches/2024-August/659909.html)
from GCC-14. the patch implements
[P2582R1 - Wording for class template argument deduction from inherited constructors](https://wg21.link/P2582R1)
which was accepted by C++23. since it's included by C++23, Clang
is also working in this direction, see
llvm/llvm-project#92606.

this is the reason why gcc-14.2.1-3 fails to build the tree, which
relies on the behavior without P2582R1.

in this change, we check for the support of P2581R1 with
CMake, and defined `SEASTAR_P2581R1` macro if the proposed
behavior is implemented. we define the argument deduction guide
for `rpc::tuple` only if this macro is not defined. this should
address the build failure. and it is future-proof as once Clang
supports P2581R1, we can detect it, and disable the dedution
guide as well.

Fixes scylladb#2445
Signed-off-by: Kefu Chai <kefu.chai@scylladb.com>

Closes scylladb#2446

(cherry picked from commit 0b752bb)
@michael-redpanda
Copy link

Force merging:

@michael-redpanda michael-redpanda merged commit ac7ce31 into v25.1.x Feb 22, 2025
0 of 29 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants