This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
RE: RE: STL debug mode
- From: "Peter Nordlund L (ERA)" <Peter dot L dot Nordlund at era dot ericsson dot se>
- To: "'Phil Edwards'" <phil at jaj dot com>
- Cc: "'libstdc++ at gcc dot gnu dot org'" <libstdc++ at gcc dot gnu dot org>
- Date: Fri, 19 Apr 2002 09:16:27 +0200
- Subject: RE: RE: STL debug mode
> -----Original Message-----
> From: Phil Edwards [mailto:phil@jaj.com]
> Sent: Friday, April 19, 2002 6:51 AM
> To: Peter Nordlund L (ERA)
> Cc: 'libstdc++@gcc.gnu.org'
> Subject: Re: STL debug mode
>
...
>
> Two that might interest you are --enable-debug and
> --enable-concept-checks.
> The first builds the library with maximal debug information
> and minimum
> optimizations. The second performs compile-time (not
> runtime) checks of
> your STL template instantiations, which often notices the
> same bugs that
> STLport's debug mode notices, but earlier.
>
>
> > If this feature is not available, is there any interest in
> implementing it?
>
> A massively-slow, massively-safe runtime is something I wouldn't mind
> providing, but nobody's come up with a good method of
> implementing it yet.
I have only tested STLPort a little. It seems ok for me.
Do you know of any problems with their approach?
> We prefer to do as many checks as we can during compilation;
> that way we can
> have them on all the time without penalizing your generated
> program speed.
>
Yes of course, but compile time checks will not catch
out of range errors etc, that are created during runtime.
I want both the most possible compile-time checks and also
most possible run-time checks :-)
/Peter