[clang][c++20] Differing behaviour vs msvc and gcc when mixing CRTP and concepts #63401
Labels
c++20
clang:frontend
Language frontend issues, e.g. anything involving "Sema"
concepts
C++20 concepts
I was implementing an idea from the following blog post and the followup discussion on Reddit so as to enforce that any CRTP derived class would implement the interfaces the CRTP base class relies on.
The code is as follows: testcase.txt
However,
clang
seems to reject this specific piece of code (https://godbolt.org/z/9KGhTPncW).What is more surprising is that it appears that both:
gcc
(https://godbolt.org/z/aWqre6rf5)msvc
(https://godbolt.org/z/fjbKPqr6j)Accept this piece of code.
This means that at least one compiler is incorrect or (highly unlikely, but you never know) the C++ standard is ambiguous in that specific case.
The text was updated successfully, but these errors were encountered: