Subject: Re: [boost] [intrusive] rtti_base class proposition
From: Ireneusz Szpilewski (irek_at_[hidden])
Date: 2009-10-21 08:54:57
Stefan Strasser wrote:
> Am Tuesday 20 October 2009 19:47:38 schrieb Ireneusz Szpilewski:
>> > Why is a common, standardized or de facto standard name needed? The
>> usual case is to create a base class for each context in which a common
>> base is desired.
> there are various solutions for this in C++ and boost.
> when you migrate from another language a common object base class might seem
> necessary, but I don't know of a case that can't be handled by void *,
> boost::any, boost::variant...
I think it would be yet another possibility, kind of smart void*.
In math, objects having special properties deserve unique name to
identify them, as 0, 1, pi. We don't have special name for number
245.43234. An empty class with sole virtual destructor
is such a special object. C++ allows RTTI iif class has a virtual
function. So the easiest way to tell someone how to RTTI-enable his
class would be to say: "Derive from rtti_base").
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk