http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44783
--- Comment #9 from Manuel López-Ibáñez <manu at gcc dot gnu.org> 2012-02-14 14:27:40 UTC --- (In reply to comment #7) > Thanks Manuel. Thus, I'm going to test your patch. Was wondering, maybe we > want > the nit: 'n_total > template_backtrace_limit + 2' n the condition, in order to > keep by default exactly the current behavior? This is why I wanted a testcase. The ones that are in the testsuite from when I added this behaviour do not trigger the "skipping message" anymore, since later I implemented recognizing the recursive template (which is much nicer IMHO). So we need a testcase that triggers this (like a very deep instantiation or something that the recursion detection cannot handle). n_total >= 12 == n_total > template_backtrace_limit + 1 The +1 is basically giving enough space, so at least we always print 2 template instantiations, one before and one after the "skipping". However, if template_backtrace_limit=1 and n_total = 2, should we print just 1 (new patch) or still 2 (old behavior)? This was not a problem before because template_backtrace_limit was always 10. > Otherwise, shall I send the patch to the mailing list for you? Thanks again. Yes, please. Feel free also to edit it or completely modify it. Thanks.