From ee18803f163c4ffcbc8f55a1aae48514d4f80521 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Mon, 20 Feb 2012 20:05:29 +0000 Subject: When we resolve the type of an 'auto' variable, clear out the linkage of that variable; it will need to be recomputed with the resolved type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150984 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/CodeGenCXX/lambda-expressions.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test/CodeGenCXX/lambda-expressions.cpp') diff --git a/test/CodeGenCXX/lambda-expressions.cpp b/test/CodeGenCXX/lambda-expressions.cpp index 203ca4d805..6f0fa87bb1 100644 --- a/test/CodeGenCXX/lambda-expressions.cpp +++ b/test/CodeGenCXX/lambda-expressions.cpp @@ -1,5 +1,8 @@ // RUN: %clang_cc1 -triple x86_64-apple-darwin10.0.0 -emit-llvm -o - %s -fexceptions -std=c++11 | FileCheck %s +// CHECK: @var = internal global +auto var = [](int i) { return i+1; }; + int a() { return []{ return 1; }(); } // CHECK: define i32 @_Z1av // CHECK: call i32 @_ZZ1avENKUlvE_clEv -- cgit v1.2.3-70-g09d2