1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 -fsyntax-only %s -verify -pedantic 2*f4a2713aSLionel Sambuc 3*f4a2713aSLionel Sambuc int X[] = { 4*f4a2713aSLionel Sambuc [4]4, // expected-warning {{use of GNU 'missing =' extension in designator}} 5*f4a2713aSLionel Sambuc [5] = 7 6*f4a2713aSLionel Sambuc }; 7*f4a2713aSLionel Sambuc 8*f4a2713aSLionel Sambuc struct foo { 9*f4a2713aSLionel Sambuc int arr[10]; 10*f4a2713aSLionel Sambuc }; 11*f4a2713aSLionel Sambuc 12*f4a2713aSLionel Sambuc struct foo Y[10] = { 13*f4a2713aSLionel Sambuc [4] .arr [2] = 4, 14*f4a2713aSLionel Sambuc 15*f4a2713aSLionel Sambuc // This is not the GNU array init designator extension. 16*f4a2713aSLionel Sambuc [4] .arr [2] 4 // expected-error {{expected '=' or another designator}} 17*f4a2713aSLionel Sambuc }; 18