Issue |
125441
|
Summary |
Clang fails to compile when using `std::tuple_size_v<T>` in concept, but compiles with `std::tuple_size<T>::value`
|
Labels |
clang
|
Assignees |
|
Reporter |
Taw3e8
|
Clang (and other compilers too) compile when this code uses `::value` but fail to compile when `_v` is used:
```cpp
template<typename T>
concept check1 = requires {
[]<std::size_t... Is>(std::index_sequence<Is...>) requires requires {
(std::get<Is>(std::declval<T>()), ...);
} {}(std::make_index_sequence<std::tuple_size<T>::value>{}); // diff
};
template<typename T>
concept check2 = requires {
[]<std::size_t... Is>(std::index_sequence<Is...>) requires requires {
(std::get<Is>(std::declval<T>()), ...);
} {}(std::make_index_sequence<std::tuple_size_v<T>>{}); // diff
};
int main() {
auto _ = check1<int>; // this is fine
auto _ = check2<int>; // this not
}
```
Is this behaviour correct?
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs