INF: Potential Problems with Identifiers Over 31 Characters

ID Number: Q48790

5.00 5.10 6.00 6.00a 6.00ax | 5.10 6.00 6.00a

MS-DOS | OS/2

Summary:

The #define statement in Microsoft C versions 5.0, 5.1, 6.0, 6.0a, and

6.0ax accepts identifiers up to 31 characters. The compiler truncates

identifiers over 31 characters, and on warning level 1 or greater,

produces the following warning message:

warning C4011: identifier truncated to '<truncated identifier>'

This can cause potential problems if two or more identifiers are

identical up to the 31st character. If this is the case, the following

warning message appears for each additional #define that is identical

when truncated (on warning levels 1 or greater):

warning C4005: '<truncated identifier>' : redefinition

All of these identifiers are assigned the value of the last identifier

that was identical when truncated.

This information also applies to QuickC.

Additional reference words: 1.0 1.00 2.0 2.00 2.01 2.5 2.50 2.51 5.00

5.10 6.00 6.00a 6.00ax