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

            Bug ID: 40700
           Summary: requires clause on a template alias is ignored
                    (Concepts TS)
           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 compiles however it should not:

template<bool condition, typename T = void>
    requires(condition)
using enable_if_t = T;

template<typename T, typename = enable_if_t<sizeof(T) < 0>>
void foo();

void test() {
    foo<int>();
}

-- 
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