On Fri, Nov 2, 2012 at 8:52 PM, Brian Brooks <[email protected]> wrote:
>>> I'm not sure I follow how this comment relates to the patch.
>
> I see that a CXXRecordDecl is created during template instantiation via
> RequireCompleteType().  The abort is triggered by dyn_cast to a
> CXXRecordDecl before it has been created.  I am not sure if the Right thing
> to do is instantiate the template here, thus creating the CXXRecordDecl,
> instead of just returning if the declarator is dependently typed.  Sorry if
> this doubt doesn't make sense.. I am still very new to the code base and the
> world of compiling.

OK, so I think you're saying that we were previously failing somewhere
inside SemaInit because we tried to initialize an S<0> from {4} when
S<0> was an incomplete type? Yes, the standard does permit (but not
require) us to trigger the instantiation of the class type here.
Regardless, your patch LGTM -- some of the checks in that function are
not appropriate for a dependently-typed variable; committed in
r167642.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to