c++/4862 and PRs marked (or not) as parser bugs
Paolo Carlini
pcarlini@unitus.it
Sat Feb 2 12:20:00 GMT 2002
"H . J . Lu" wrote:
> I have sent a testcase long time ago:
>
> http://gcc.gnu.org/ml/gcc-patches/2001-08/msg01378.html
>
> Are they the same thing? Here is a patch I have been using without any
> problem. BTW, I have no ideas what I am doing.
:-)
How about c++/5577?? Does it fix this one too?? In that case it would be really nice
to have it for 3.1 too...
Cheers,
Paolo.
//////////////
template<typename coeftype>
struct IIR {
IIR () {}
template <class outputtype>
outputtype Compute (coeftype x) {
return outputtype();
}
};
// This is Ok.
IIR<double> iir;
double out_iir = iir.Compute<double>(0.0);
// This is Ok.
struct JTC_fading2 {
void Iterate () {
double out_iir = iir.Compute<double>(0.0);
}
IIR<double> iir;
};
// This is NOT Ok.
template<typename rng_t>
struct JTC_fading {
void Iterate () {
double out_iir = iir.Compute<double>(0.0); // <- Error
}
IIR<double> iir;
};
//////////
More information about the Gcc
mailing list