|
|
Lutz Kretzschmar <lut### [at] stmuccom> wrote:
: Generally, I agree, but not in this case. And you failed to answer my
: question. How do create a copy of an object to which you have a base
: class pointer.
I would probably not design the program at all in a way that I will be
needing copying objects behind base class pointers. If nothing else, I would
probably make a more abstract "handle" to that resource which safely takes
care of creating, copying and destroying it.
:> The whole class hierarchy should be designed so that this kind of copying
:> is not needed (ie. not in this way).
: Very funny. There is no amount of design that can avoid this.
Well, I have coded tens of thousands of lines of object-oriented C++ code
as my work, and I have never needed to do this.
--
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}// - Warp -
Post a reply to this message
|
|