1*f4a2713aSLionel Sambuc // RUN: %clang_cc1 %s -verify -fsyntax-only -pedantic 2*f4a2713aSLionel Sambuc // expected-no-diagnostics 3*f4a2713aSLionel Sambuc 4*f4a2713aSLionel Sambuc // This file tests the clang extension which allows initializing the components 5*f4a2713aSLionel Sambuc // of a complex number individually using an initialization list. Basically, 6*f4a2713aSLionel Sambuc // if you have an explicit init list for a complex number that contains two 7*f4a2713aSLionel Sambuc // initializers, this extension kicks in to turn it into component-wise 8*f4a2713aSLionel Sambuc // initialization. 9*f4a2713aSLionel Sambuc // 10*f4a2713aSLionel Sambuc // See also the testcase for the C version of this extension in 11*f4a2713aSLionel Sambuc // test/Sema/complex-init-list.c. 12*f4a2713aSLionel Sambuc 13*f4a2713aSLionel Sambuc // Basic testcase 14*f4a2713aSLionel Sambuc // (No pedantic warning is necessary because _Complex is not part of C++.) 15*f4a2713aSLionel Sambuc _Complex float valid1 = { 1.0f, 2.0f }; 16