On 28 Jan., 11:36, SG wrote:
>
> In the following C++0x code I tried to clone an object by using a
> clone member function (if it exists) and fall back on a copy
> constructor:
>
> [...]
>
> Unfortunately, GCC 4.5.1 doesn't accept this program:
>
> [...]
>
> Now, the question is, is this a compiler bug or was I wrong to assume
> that SFINAE applies here?
I convinced myself that this is another case where GCC ignores the
"NAE" in SFINAE in combination with templates and decltype and filed a
bug report:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47513
Cheers!
SG