<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">On Thu, Jun 25, 2015 at 1:13 PM Richard Smith <<a href="mailto:richard@metafoo.co.uk">richard@metafoo.co.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">================<br>
Comment at: lib/Sema/SemaTemplateInstantiate.cpp:1930-1939<br>
@@ -1929,12 +1929,12 @@<br>
<br>
   // \brief Record the point of instantiation.<br>
   if (MemberSpecializationInfo *MSInfo<br>
         = Instantiation->getMemberSpecializationInfo()) {<br>
     MSInfo->setTemplateSpecializationKind(TSK);<br>
     MSInfo->setPointOfInstantiation(PointOfInstantiation);<br>
   } else if (ClassTemplateSpecializationDecl *Spec<br>
         = dyn_cast<ClassTemplateSpecializationDecl>(Instantiation)) {<br>
     Spec->setTemplateSpecializationKind(TSK);<br>
     Spec->setPointOfInstantiation(PointOfInstantiation);<br>
   }<br>
<br>
----------------<br>
Is it sufficient to move this block of code to after the bail-out below? It seems like the problem may be that we've done some amount of the instantiation work (storing the TSK on the specialization) before we bail out, and so the AST is left in an inconsistent state.<br></blockquote><div><br></div><div>Doesn't work, we still crash...</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_D10622&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=BSqEv9KvKMW_Ob8SyngJ70KdZISM_ASROnREeq0cCxk&m=x2xhg-8e5N6EzXPvydyo8evnVL2t3tM02yY-rBEojXs&s=TCDNAqQbCbm_y52dDxoQDN68uLjU0DBTY7n8qntMHVM&e=" rel="noreferrer" target="_blank">http://reviews.llvm.org/D10622</a><br>
<br>
EMAIL PREFERENCES<br>
  <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__reviews.llvm.org_settings_panel_emailpreferences_&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=BSqEv9KvKMW_Ob8SyngJ70KdZISM_ASROnREeq0cCxk&m=x2xhg-8e5N6EzXPvydyo8evnVL2t3tM02yY-rBEojXs&s=yuNJz3K6qHl5B1_cAHQRemJG4thr5Rg6kbO9R_RoCWA&e=" rel="noreferrer" target="_blank">http://reviews.llvm.org/settings/panel/emailpreferences/</a><br>
<br>
<br>
</blockquote></div></div>