9 Nov
2008
9 Nov
'08
9:50 a.m.
Terry G wrote:
I'm playing with move semantics (still/again).
The following program compiles and runs fine with msvc8 but does not compile with gcc 4.3.0 when ENABLE_IS_CONVERTIBLE_CHECK is defined. Should it? The problem has something to do with U's copy constructor being private. I've inluded the compiler output below too.
Without some compiler supplied magic, is_convertible will fail to compile if the conversion involves a protected or private constructor. Sorry, but it's a limitation of the implementation/language. John.