Bug in coerce_templates

Kriang Lerdsuwanakij lerdsuwa@scf-fs.usc.edu
Tue Mar 17 01:50:00 GMT 1998


Martin von Loewis wrote:
> 
> Kriang,
> 
> Thanks for your patch. It doesn't really fix ttp26.C, though,
> as it dies a couple of lines later in
> 
>               my_friendly_assert (!require_all_arguments, 0);
> 
> This is because is_tmpl_parm is zero, even though i<nargs.
> The call to coerce_templates comes from unify:
> 
>             if (coerce_template_parms (argtmplvec, parmvec, parmtmpl, 1, 1, 0)
>                 == error_mark_node)
>               return 1;
> 
> Martin

I discovered that shortly later too.  In my opinion in the condition of
else if, only i<nargs is needed, the condition is_tmpl_parm sounds
unrelated.  I'll do more tests on that part of code at that tomorrow.  

Kriang



More information about the Gcc-bugs mailing list