RE: multiple inheritance question - c++ |
||
![]() ![]() Epsilon Maj Pain in the Ass I just tested it for kicks and moving this from Rectangle to Drawable does the trick: int getItsLength() const {return *itsLength;}
int getItsWidth() const {return *itsWidth;}
protected:
int *itsLength;
int *itsWidth;
Output as expected:
gabb@downtime:~$ vi test.cpp gabb@downtime:~$ g++ test.cpp -o test gabb@downtime:~$ ./test xxxx xxxx xxxx xxxx gabb@downtime:~$ Replies:
|
||
| CyberArmy::Forum v0.6 Generated In 0.01409 seconds |