This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
RE: [libstdc++] Don't access fpos_t.__state on uClibc w/o wchar support
- From: Pétur Runólfsson <peturr02 at ru dot is>
- To: "Bernardo Innocenti" <bernie at develer dot com>
- Cc: "Gabriel Dos Reis" <gdr at integrable-solutions dot net>,"GCC Patches" <gcc-patches at gcc dot gnu dot org>,<libstdc++ at gcc dot gnu dot org>
- Date: Thu, 25 Sep 2003 19:12:43 -0000
- Subject: RE: [libstdc++] Don't access fpos_t.__state on uClibc w/o wchar support
Bernardo Innocenti wrote:
> We just need to disable code that needs that missing member and
> perhaps return a default value instead.
If your platform doesn't support any stateful conversions, then this
seems reasonable, but in general less platform-specific code is
usually better.
> I also have a philosophical question: does libstdc++ need to
> provide all the features mandated by the standard even when
> the underlying C library doesn't support them properly?
Depends on what you mean by need :-)
> In embedded projects, I'd rather like an incomplete libstdc++
> than a needlessly fat one. I don't use locales, UTF8 or wide
> streams, therefore I'd like to drop all code for dealing with
> them.
Ideally, the linker should be able to discard those parts of the
library that are not used. It may need some help though, such as
splitting up source files and using weak symbols. #ifdefs to
reduce code size should be used only as a last resort (if at all).
Petur