<html><head><meta http-equiv="Content-Type" content="text/html charset=iso-8859-1"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">LGTM<div><br><div><div>On Nov 2, 2012, at 1:50 PM, Richard Trieu <<a href="mailto:rtrieu@google.com">rtrieu@google.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div style="font-family: arial, helvetica, sans-serif; font-size: 10pt">On Tue, Oct 9, 2012 at 5:05 PM, Richard Trieu <span dir="ltr"><<a href="mailto:rtrieu@google.com" target="_blank">rtrieu@google.com</a>></span> wrote:<br>
<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tue, Oct 9, 2012 at 5:04 PM, Richard Trieu <span dir="ltr"><<a href="mailto:rtrieu@google.com" target="_blank">rtrieu@google.com</a>></span> wrote:<br>
<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
The following code causes a crash:<div><br></div><div><div>template<typename T> class vector2 {};</div><div>template<typename T> class vector : vector2<T> {};</div><div><br></div><div>template<typename T> void Foo(vector<const T*> V) {}</div>


<div><br></div><div>void test() {</div><div>  Foo(vector<int*>());</div><div>}</div></div><div><br></div><div>Once template deduction fails in vector, it tries again with with the base class vector2 and also fails, but with a different status.  However, the TemplateDeductionInfo is updated, but the old status is kept.  This leads to an assert later when the diagnostic is produced.  This patch introduces a temporary TemplateDeductionInfo to capture the information from the base class template deduction, and only overrides the old info if the template deduction is successful.</div>


</blockquote></div><br></div></div><div>Oops.  And here's the patch.</div>
</blockquote></div><div><br></div>Ping.</div>
_______________________________________________<br>cfe-commits mailing list<br><a href="mailto:cfe-commits@cs.uiuc.edu">cfe-commits@cs.uiuc.edu</a><br>http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits<br></blockquote></div><br></div></body></html>