[PATCH] CodeGen: Fix linkage of reference temporaries
David Majnemer
david.majnemer at gmail.com
Fri Apr 25 10:16:29 PDT 2014
Hi rsmith,
A reference temporary should inherit the linkage of the variable it
initializes. Otherwise, we may hit cases where a reference temporary
wouldn't have the same value in all translation units.
http://reviews.llvm.org/D3515
Files:
lib/CodeGen/CodeGenModule.cpp
test/CodeGenCXX/const-init-cxx11.cpp
test/CodeGenCXX/const-init-cxx1y.cpp
test/CodeGenCXX/cxx0x-initializer-stdinitializerlist-pr12086.cpp
test/CodeGenCXX/cxx0x-initializer-stdinitializerlist-startend.cpp
test/CodeGenCXX/cxx0x-initializer-stdinitializerlist.cpp
test/CodeGenCXX/cxx11-thread-local.cpp
test/CodeGenCXX/temporaries.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D3515.8852.patch
Type: text/x-patch
Size: 16984 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140425/061902c2/attachment.bin>
More information about the cfe-commits
mailing list