C/C++ Compiler (cl.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
Changing Default Character Type (/J)
                                             Up Contents Index Back
─────C/C++ Compiler─────────────────────────────────────────────────────────
 
     Syntax:  /J
 
     The /J option changes the default char type from signed to
     unsigned. This option is useful when working with character data
     that will eventually be translated into a language other than
     English. If a char value is explicitly declared signed, the /J
     option does not affect it, and the value is sign-extended when
     widened to int type. The char type is zero-extended when widened
     to int type.
 
     When you specify /J, the compiler automatically defines the
     identifier _CHAR_UNSIGNED, which is used with #ifndef in the
     LIMITS.H include file to define the range of the default char type.
 
     Neither ANSI C nor C++ requires a specific implementation of the
     char type.
                                    -♦-