#pragma chars

Category

Floating-point and integer control

Purpose

Determines whether all variables of type char are treated as either signed or unsigned.

Syntax

Pragma syntax


1  # pragma chars (
2.1 signed
2.1! unsigned
1 )

Defaults

See the CHARS option in the z/OS XL C/C++ User's Guide.

Parameters

unsigned
Variables of type char are treated as unsigned char.
signed
Variables of type char are treated as signed char.

Usage

Regardless of the setting of this pragma, the type of char is still considered to be distinct from the types unsigned char and signed char for purposes of type-compatibility checking or C++ overloading.

If the pragma is specified more than once in the source file, the first one will take precedence. Once specified, the pragma applies to the entire file and cannot be disabled; if a source file contains any functions that you want to compile without #pragma chars, place these functions in a different file. C onlyThe pragma must appear before any source statements, except for the pragmas filetag, longname, langlvl or target, which may precede it.C++ onlyThe pragma must appear before any source statements.

Related information