This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/64931] ICE on function with deduced return type and input is instantiated template class


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.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]