This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/64931] ICE on function with deduced return type and input is instantiated template class
- From: "mpolacek at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 23 Mar 2015 13:39:22 +0000
- Subject: [Bug c++/64931] ICE on function with deduced return type and input is instantiated template class
- Auto-submitted: auto-generated
- References: <bug-64931-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64931
Marek Polacek <mpolacek at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mpolacek at gcc dot gnu.org
--- Comment #2 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Slightly more reduced:
template<typename T>
struct S {
T data[32];
};
auto
foo (S<int> & x)
{
return x;
}
The problem is that we create a RESULT_DECL with NULL DECL_SIZE, and gimplifier
ICEs on that. The RESULT_DECL is created in convert_for_initialization called
from check_return_expr I think.