Re: [Doxygen-users] HOW DO I iterate thru Doxygen::GroupList and GroupDef to get grou ped classes an
Brought to you by:
dimitri
|
From: mldb <ml...@gm...> - 2001-06-29 14:57:50
|
RC> From: Rodolfo Cazabon <rod...@au...>
RC> Hi everyone...
[snip]
RC> Second, I cheated, and declared these as PUBLIC...but when I do the
RC> following :
RC> ClassListIterator cli(p_groupDef->classList);
RC> ClassDef *cd;
RC> for (cli.toFirst();(cd=cli.current());++cli)
RC> {
RC> printf("%S \n", cd->name() );
RC> }
RC> I get a crash because that pointer is not valid!
I suspect, you missed the fact, that printf has a vararg signature
(printf(const char *fmt,...)). The "const char *" conversion of
QCString (this is what cd->name() is) is not used, since the compiler
does not know *to what* you want it to be converted: '...' could be
anything.
printf("%s \n", (const char*)cd->name());
should work
--
Marco
|