]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | /*============================================================================= |
2 | Boost.Wave: A Standard compliant C++ preprocessor library | |
3 | http://www.boost.org/ | |
4 | ||
5 | Copyright (c) 2001-2012 Hartmut Kaiser. Distributed under the Boost | |
6 | Software License, Version 1.0. (See accompanying file | |
7 | LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | |
8 | =============================================================================*/ | |
9 | ||
10 | // Tests, whether invalid expression errors get ignored for 'passive' #elif | |
11 | // expressions | |
12 | #define USHRT_MAX 0xffffU | |
13 | ||
14 | // The number of bytes in a short. | |
15 | # if !defined (SIZEOF_SHORT) | |
16 | # if (USHRT_MAX) == 255U | |
17 | # define SIZEOF_SHORT 1 | |
18 | # elif (USHRT_MAX) == 65535U | |
19 | # define SIZEOF_SHORT 2 | |
20 | # elif (USHRT_MAX) == 4294967295U | |
21 | # define SIZEOF_SHORT 4 | |
22 | # elif (USHRT_MAX) == 18446744073709551615U | |
23 | # define SIZEOF_SHORT 8 | |
24 | # else | |
25 | # error: unsupported short size, must be updated for this platform! | |
26 | # endif /* USHRT_MAX */ | |
27 | # endif /* !defined (SIZEOF_SHORT) */ | |
28 | ||
29 | //R #line 32 "t_4_004.cpp" | |
30 | //R true | |
31 | #if SIZEOF_SHORT == 2 | |
32 | true | |
33 | #else | |
34 | false | |
35 | #endif | |
36 | ||
37 | //H 10: t_4_004.cpp(12): #define | |
38 | //H 08: t_4_004.cpp(12): USHRT_MAX=0xffffU | |
39 | //H 10: t_4_004.cpp(15): # if | |
40 | //H 11: t_4_004.cpp(15): # if !defined (SIZEOF_SHORT): 1 | |
41 | //H 10: t_4_004.cpp(16): # if | |
42 | //H 01: t_4_004.cpp(12): USHRT_MAX | |
43 | //H 02: 0xffffU | |
44 | //H 03: 0xffffU | |
45 | //H 11: t_4_004.cpp(16): # if (USHRT_MAX) == 255U: 0 | |
46 | //H 10: t_4_004.cpp(18): # elif | |
47 | //H 01: t_4_004.cpp(12): USHRT_MAX | |
48 | //H 02: 0xffffU | |
49 | //H 03: 0xffffU | |
50 | //H 11: t_4_004.cpp(18): # elif (USHRT_MAX) == 65535U: 1 | |
51 | //H 10: t_4_004.cpp(19): #define | |
52 | //H 08: t_4_004.cpp(19): SIZEOF_SHORT=2 | |
53 | //H 10: t_4_004.cpp(20): # elif | |
54 | //H 10: t_4_004.cpp(22): # elif | |
55 | //H 10: t_4_004.cpp(27): # endif | |
56 | //H 10: t_4_004.cpp(31): #if | |
57 | //H 01: t_4_004.cpp(19): SIZEOF_SHORT | |
58 | //H 02: 2 | |
59 | //H 03: 2 | |
60 | //H 11: t_4_004.cpp(31): #if SIZEOF_SHORT == 2: 1 | |
61 | //H 10: t_4_004.cpp(33): #else |