
20 Apr
2008
20 Apr
'08
11:37 a.m.
Richard Webb wrote:
Following on with the type_traits failures with is_polymorphic (http://tinyurl.com/6jq57y):
If you have:
class foo { public: virtual ~foo() {
} };
class bar : virtual public foo { public: virtual ~bar() {
} };
Then boost::is_polymorphic<bar> is true, but mstr1::is_polymorphic<bar> is false.
If i either: -make foos destructor non-virtual -add an additional virtual method to bar -change the defintion of bar to 'class bar : public foo'
then mstr1::is_polymorphic<bar> becomes true. MS Bug?
Most strange, yes it looks like a bug to me, I mean the class is defininely polymorphic right? In any case *removing* a virtual destructor surely can't move a class from non-polymorphic to polymorphic ! :-) John.