Hi..
I have a sockclass that will be used in linkedlist separetly and also in another class (aclass) with its public members.
Code:class sclass { public: int member; int sth; SOCKET s; sclass *next; }
Now what would be the best way to use *next pointer in both cases for linked list? To leave it as it is, or to put void *pointer in sclass and then point to sclass or aclass (if I will use aclass with public members of sclass), or just leave it as it is? I want my code to be professional, so Im asking for your advice..Code:class aclass : public sclass { public: char *p; aclass *next; }
What do you think would be the best way to do it?
Thanks for help
Kind regards



LinkBack URL
About LinkBacks


