This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/21238] conflicting "typedef __numpunct_cache<_CharT> __cache_type;" in std::numpunct<CharT> makes specialization impossible
- From: "pcarlini at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 27 Apr 2005 12:12:51 -0000
- Subject: [Bug libstdc++/21238] conflicting "typedef __numpunct_cache<_CharT> __cache_type;" in std::numpunct<CharT> makes specialization impossible
- References: <20050426232113.21238.bduerner@gmx.de>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pcarlini at suse dot de 2005-04-27 12:12 -------
Thanks for the testcase. The issue is subtle and the typedef is only the tip of
the iceberg: num_get (involved in >>(int)) uses the caching facilities provided
by the primary numpunct, which a specialization simply misses, generally. As our
library is currently designed, you cannot specialize numpunct and then use the
primary num_get template with it. Maybe we have a slighlty different instance
of the problem with istream members that we fixed for 4.0: we should have generic
implementations of num_get (and num_put) not exploitng any numpunct-provided
caching and efficient specializations for char and wchar_t. Seems doable, at
the expense of a non-trivial code-growth, but maybe within the present ABI.
Benjamin?
--
What |Removed |Added
----------------------------------------------------------------------------
CC| |bkoz at redhat dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21238