This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/67164] ICE: tree check: expected class âexpressionâ, have âexceptionalâ (argument_pack_select) in tree_operand_check, at tree.h:3356
- From: "ldionne.2 at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 27 Feb 2016 20:34:17 +0000
- Subject: [Bug c++/67164] ICE: tree check: expected class âexpressionâ, have âexceptionalâ (argument_pack_select) in tree_operand_check, at tree.h:3356
- Auto-submitted: auto-generated
- References: <bug-67164-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67164
--- Comment #6 from Louis Dionne <ldionne.2 at gmail dot com> ---
The code I posted above does not seem to trigger the bug anymore on GCC trunk.
However, the following code still produces an ICE on trunk:
> ~/code/gcc/prefix/bin/g++ --version
> g++ (GCC) 6.0.0 20160226 (experimental)
------------------------------------------------------------------------------
#include <type_traits>
namespace detail {
template <bool ...b>
struct fast_and
: std::is_same<fast_and<b...>, fast_and<(b, true)...>>
{ };
}
template <typename ...Xn>
struct tuple {
tuple() { }
template <typename ...Yn, typename = typename std::enable_if<
detail::fast_and<std::is_constructible<Xn, Yn&&>::value...>::value
>::type>
tuple(Yn&& ...yn) { }
template <typename ...Yn, typename = typename std::enable_if<
detail::fast_and<std::is_constructible<Xn, Yn const&>::value...>::value
>::type>
tuple(tuple<Yn...> const& other) { }
};
tuple<tuple<>> t{};
tuple<tuple<>> copy = t;
------------------------------------------------------------------------------