Re: pointer question
Re: pointer question
- Subject: Re: pointer question
- From: Candide Kemmler <email@hidden>
- Date: Tue, 3 Jul 2001 14:43:03 +0200
:-( I forgot to initialize roadIdx to 0 at first !
stupid C ! couldn't the compiler just initialize an int to 0 when you
declare it, like Java ?
Incidentally, this would all be considerably easier if you were working
in Objective-C.
Yes, I guess so, but then, how do you make a qsort on your Objective-C
objects ? As of with my array, I just do:
qsort ( roadStore, roadIdx, sizeof ( struct road ), compareRoads );
I've heard of something like the STL or so, doing things like the
Collection Framework in Java, but for C++. With it you could sort all
kinds of objects, construct complex data structures over which you can
easily iterate, etc... Sounds great ! Is there something similar for
Objective-C ? I'd love there was, but I don't think such a thing
exists... Does it ?
Regards,
Candide