[Bug c++/25278] g++ seems to ignore an overloaded function.
theodore dot papadopoulo at sophia dot inria dot fr
gcc-bugzilla@gcc.gnu.org
Tue Dec 6 18:46:00 GMT 2005
------- Comment #3 from theodore dot papadopoulo at sophia dot inria dot fr 2005-12-06 18:46 -------
(In reply to comment #0)
> The code attached does not compile since version 4.0 of gcc.
> Remove either the Cpu namespace or one element in the enumeration or replace
> the array size in RGBPixel by a constant and the bug disappears.
>
> It looks as if g++ ignores the overload for ChangeEndianness(RGB<T>&) when it
> calls it from ChangeEndianness(T* begin,const T* end) so that the generic
> version ChangeEndianness(T& t) is called instead generating and error because
> the default class for SwapEndianness does not contain any swap method.
>
> This has been tested with gcc version 4.2.0 20051206 (experimental).
>
> Note also that things slightly improved since
> gcc version 4.2.0 20051124 (experimental)
> which failed also if the enumeration only had two elements (instead of three
> now).
>
> All this is a regression since gcc-3.4.
>
--
theodore dot papadopoulo at sophia dot inria dot fr changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |UNCONFIRMED
Resolution|INVALID |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25278
More information about the Gcc-bugs
mailing list