Sun WorkShop Compiler C 5.0 User's Guide

Character Constants

A multiple-character constant that is not an escape sequence has a value derived from the numeric values of each character. For example, the constant '123' has a value of:

Table 3-2 Multiple-character Constant (ANSI/ISO)

0

'3'

'2'

'1'

or 0x333231.

With the -Xs option and in other, non-ANSI/ISO versions of C, the value is:

Table 3-3 Multiple-character Constant (non-ANSI/ISO)

0

'1'

'2'

'3'

or 0x313233.