January 07, 2002 ClassInfo | ||||
---|---|---|---|---|
| ||||
A few questions about subj. First of all, I declared three different classes, but they seem to share one common classinfo (I printf'ed the pointer). Why isn't ClassInfo.name there, not even pointing to a valid memory location ("access violation"). And finally, what is ClassInfo.init? I saw it being used in OutOfMemory class, but didn't get the idea... is it a pointer to the constructor, or a pointer to static members of the class, or what? Also, it would be really cool to add pointer to constructor to ClassInfo if it's not already there, and form some globally accessible list of ClassInfo's - array, or linked list, or whatever else. This could be used to implement object serialization, for example. |
January 11, 2002 Re: ClassInfo | ||||
---|---|---|---|---|
| ||||
Posted in reply to Pavel Minayev | I'll check into the bugs. -Walter "Pavel Minayev" <evilone@omen.ru> wrote in message news:a1cjog$1acn$1@digitaldaemon.com... > A few questions about subj. > > First of all, I declared three different classes, but they seem to share one common classinfo (I printf'ed the pointer). > > Why isn't ClassInfo.name there, not even pointing to > a valid memory location ("access violation"). > > And finally, what is ClassInfo.init? I saw it being used > in OutOfMemory class, but didn't get the idea... is it > a pointer to the constructor, or a pointer to static > members of the class, or what? > > Also, it would be really cool to add pointer to constructor > to ClassInfo if it's not already there, and form some > globally accessible list of ClassInfo's - array, or > linked list, or whatever else. This could be used to > implement object serialization, for example. > > |
Copyright © 1999-2021 by the D Language Foundation