This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: MULTIBYTE_CHARS in c-lex.c and cp/lex.c




Gavin Romig-Koch wrote:

> There is a undef at the top of c-lex.c that turns off MULTIBYTE_CHARS
> if CROSS_COMPILE is set.  There is not a similar undef at the top
> of cp/lex.c.  Can anybody shed light on why the difference?
>
> Is it because cp/lex.c is always built with gcc, while c-lex.c might
> be built with some other compiler?

The one in c-lex.c should probably be removed. The rationale for it being
there is that the compiler can only recognize and convert multibyte
characters using information provided by the host locale, which may not
make any sense for the target when cross compiling. However, we have
support for several pseudo-locales (C-JIS, C-SJIS, C-EUCJP) which could
be useful in a cross compiler and other host-locale character sets may
also be valid on the target of a cross compiler. So I say, leave it
enabled for cross compilers as well.

Dave


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]