[Bug c++/95324] New: Segmentation fault when using variadic lambda template in concept definition
ivan.pogrebnyak at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon May 25 22:56:02 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95324
Bug ID: 95324
Summary: Segmentation fault when using variadic lambda template
in concept definition
Product: gcc
Version: 10.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: ivan.pogrebnyak at gmail dot com
Target Milestone: ---
Created attachment 48600
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=48600&action=edit
gcc version, output, and -save-temps
Definition of the following concept (using C++20) causes segmentation fault in
GCC 10.1.0.
template <typename F, typename T>
concept Applyable =
[]<size_t... I>(std::index_sequence<I...>) {
return std::is_invocable_v<F,std::tuple_element_t<I,T>...>;
}(std::make_index_sequence<std::tuple_size_v<T>>{});
Refactoring the definition into a `constexpr bool` and using it in the concept
definition works.
See the attachment for details.
More information about the Gcc-bugs
mailing list