public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* _GLIBCPP_USE_WCHAR_T undefined in FreeBSD's c++config.h?
@ 2003-02-19 18:07 Craig Rodrigues
  2003-02-19 18:23 ` Benjamin Kosnik
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Craig Rodrigues @ 2003-02-19 18:07 UTC (permalink / raw)
  To: gcc; +Cc: libstdc++

Hi,

I am not sure if this issue falls under the jurisdiction of
the gcc@ or libstdc++@ mailing lists so I am posting to both.

I am running FreeBSD:
uname -a
FreeBSD 5.0-CURRENT #15



If I bootstrap gcc 3.3 branch, I notice that
include/c++/3.3/i386-unknown-freebsd5.0/bits/c++config.h
does not define _GLIBCPP_USE_WCHAR_T as it does under Linux.

This makes it impossible to compile the following snippet of
code:

#include <string>

using namespace std;

int main(int argc, char *argv[])
{
  std::wstring a;
  return 0;
}


a.cc: In function `int main(int, char**)':
a.cc:7: error: `wstring' undeclared in namespace `std'
a.cc:7: error: parse error before `;' token


The reason for this is because in include/c++/3.3/bits/stringfwd.h, 
we have:


#ifdef _GLIBCPP_USE_WCHAR_T
  template<> struct char_traits<wchar_t>;

  typedef basic_string<wchar_t> wstring;
#endif


What is the solution for this?

Thanks.
-- 
Craig Rodrigues        
http://home.attbi.com/~rodrigc
rodrigc@attbi.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2003-02-20 17:57 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-02-19 18:07 _GLIBCPP_USE_WCHAR_T undefined in FreeBSD's c++config.h? Craig Rodrigues
2003-02-19 18:23 ` Benjamin Kosnik
2003-02-19 18:25 ` Alexander Kabaev
2003-02-19 20:07   ` Benjamin Kosnik
2003-02-20 18:11     ` Phil Edwards
2003-02-20 13:57   ` Craig Rodrigues
2003-02-19 19:11 ` Karel Gardas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).