Home | History | Annotate | Download | only in expr.prim.lambda
      1 // RUN: %clang_cc1 -fsyntax-only -std=c++11 %s -verify
      2 
      3 void test_nonaggregate(int i) {
      4   auto lambda = [i]() -> void {}; // expected-note 2{{candidate constructor}}
      5   decltype(lambda) foo = { 1 }; // expected-error{{no matching constructor}}
      6   static_assert(!__is_literal(decltype(lambda)), "");
      7 
      8   auto lambda2 = []{}; // expected-note 2{{candidate constructor}}
      9   decltype(lambda2) bar = {}; // expected-error{{no matching constructor}}
     10   static_assert(!__is_literal(decltype(lambda2)), "");
     11 }
     12