[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A couple of C++ game-related questions

Dennis Payne wrote:

> > First of all, is there an STL implementation for Linux? Or something
> > similar? What do you guys do for linked lists? Do you make your own/use
> > and old one that you made?
> An STL implementation is included with g++.  A lot of the STL and other
> standard C++ features have been added recently so if you want to run on
> older systems you may want to limit your use.  In general I make limited
> use of STL but I'm using an old compiler that doesn't support that much.
> (As soon as my new laptop arrives that may change :)

As for "if you want to run on older systems", the STL is templates, and
templates could be explained as #defines on steroids. They are
statically instantiated by the compiler at compilation time and do not
require any help from the runtime library. (in a general way, maybe some
templates uses (in their generated code) functions from a particular
version of the runtime library)

Pierre Phaneuf
Ludus Design, http://ludusdesign.com/
"First they ignore you. Then they laugh at you.
Then they fight you. Then you win." -- Gandhi