File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -113,20 +113,17 @@ int somefunc(int i) {
113113
114114/// FIXME: The following test is incorrect in the new interpreter.
115115/// The null pointer returns 16 from its getIntegerRepresentation().
116+ #pragma clang diagnostic ignored "-Wpointer-to-int-cast"
116117struct ArrayStruct {
117118 char n [1 ];
118119};
119120struct AA {
120- char name2 [(int )& ((struct ArrayStruct * )0 )-> n - 1 ]; // expected-warning {{cast to smaller integer type}} \
121- // expected-warning {{folded to constant array}} \
122- // pedantic-expected-warning {{cast to smaller integer type}} \
121+ char name2 [(int )& ((struct ArrayStruct * )0 )-> n - 1 ]; // expected-warning {{folded to constant array}} \
123122 // pedantic-expected-warning {{folded to constant array}} \
124123 // ref-error {{array size is negative}} \
125- // ref-warning {{cast to smaller integer type}} \
126- // pedantic-ref-error {{array size is negative}} \
127- // pedantic-ref-warning {{cast to smaller integer type}}
124+ // pedantic-ref-error {{array size is negative}}
128125};
129126_Static_assert (sizeof (struct AA ) == 15 , "" ); // ref-error {{failed}} \
130- // ref-note {{1 == 15}} \
127+ // ref-note {{ == 15}} \
131128 // pedantic-ref-error {{failed}} \
132- // pedantic-ref-note {{1 == 15}}
129+ // pedantic-ref-note {{ == 15}}
You can’t perform that action at this time.
0 commit comments