https://bugs.llvm.org/show_bug.cgi?id=50693

            Bug ID: 50693
           Summary: `requires` out-of-line definition using typedef not
                    accepted
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++2a
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected]

The following code
(Godbolt link https://godbolt.org/z/d756fhMTh)
is not accepted by clang but is accepted by GCC:

#include <type_traits>

template<typename T>
struct S
{
    using t = T;

    void f()
    requires(std::is_copy_constructible_v<t>);
};

template<typename T>
auto S<T>::f() -> void
// requires(std::is_copy_constructible_v<T>)
requires(std::is_copy_constructible_v<typename S<T>::t>)
{
}

int main()
{
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to