ORCA-C/Tests/Deviance/D2.7.1.1.CC

29 lines
1.1 KiB
C++

/* Deviance Test 2.7.1.1: Ensure misformed integers are flagged as errors */
int printf(const char *, ...);
int main (void)
{
int a;
a = 32t79; /* invalid character embedded in digit sequence */
a = 14f; /* floating-pt type marker only used with reals */
a = 28F;
a = 12FA; /* decimal number with embedded hex digits */
a = 04FC; /* octal number with embedded hex digits */
/* octal number with more than 255 characters */
a = 000000000000000000000000000000000000000000000000000000000000\
0000000000000000000000000000000000000000000000000000000000000000000\
0000000000000000000000000000000000000000000000000000000000000000000\
00000000000000000000000000000000000000000000000000000000000003;
/* hex number with more than 255 characters */
a = 0X0000000000000000000000000000000000000000000000000000000000\
0000000000000000000000000000000000000000000000000000000000000000000\
0000000000000000000000000000000000000000000000000000000000000000000\
00000000000000000000000000000000000000000000000000000000000003FFA;
printf ("Failed Deviance Test 2.7.1.1\n");
}