<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Feb 16, 2015 at 10:21 AM, Aaron Ballman <span dir="ltr"><<a href="mailto:aaron@aaronballman.com" target="_blank">aaron@aaronballman.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: aaronballman<br>
Date: Mon Feb 16 12:21:19 2015<br>
New Revision: 229414<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=229414&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=229414&view=rev</a><br>
Log:<br>
MSVC 2013 supports std::forward_as_tuple, while MSVC 2012 did not; so we can move to using the improved API.<br></blockquote><div><br>Heh, thanks! That one made me sad.<br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Modified:<br>
llvm/trunk/lib/CodeGen/LexicalScopes.cpp<br>
<br>
Modified: llvm/trunk/lib/CodeGen/LexicalScopes.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LexicalScopes.cpp?rev=229414&r1=229413&r2=229414&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LexicalScopes.cpp?rev=229414&r1=229413&r2=229414&view=diff</a><br>
==============================================================================<br>
--- llvm/trunk/lib/CodeGen/LexicalScopes.cpp (original)<br>
+++ llvm/trunk/lib/CodeGen/LexicalScopes.cpp Mon Feb 16 12:21:19 2015<br>
@@ -168,11 +168,10 @@ LexicalScope *LexicalScopes::getOrCreate<br>
LexicalScope *Parent = nullptr;<br>
if (D.isLexicalBlock())<br>
Parent = getOrCreateLexicalScope(DebugLoc::getFromDILexicalBlock(Scope));<br>
- // FIXME: Use forward_as_tuple instead of make_tuple, once MSVC2012<br>
- // compatibility is no longer required.<br>
- I = LexicalScopeMap.emplace(std::piecewise_construct, std::make_tuple(Scope),<br>
- std::make_tuple(Parent, DIDescriptor(Scope),<br>
- nullptr, false)).first;<br>
+ I = LexicalScopeMap.emplace(std::piecewise_construct,<br>
+ std::forward_as_tuple(Scope),<br>
+ std::forward_as_tuple(Parent, DIDescriptor(Scope),<br>
+ nullptr, false)).first;<br>
<br>
if (!Parent) {<br>
assert(DIDescriptor(Scope).isSubprogram());<br>
@@ -199,12 +198,11 @@ LexicalScope *LexicalScopes::getOrCreate<br>
else<br>
Parent = getOrCreateInlinedScope(Scope.getContext(), InlinedAt);<br>
<br>
- // FIXME: Use forward_as_tuple instead of make_tuple, once MSVC2012<br>
- // compatibility is no longer required.<br>
I = InlinedLexicalScopeMap.emplace(std::piecewise_construct,<br>
- std::make_tuple(P),<br>
- std::make_tuple(Parent, Scope, InlinedAt,<br>
- false)).first;<br>
+ std::forward_as_tuple(P),<br>
+ std::forward_as_tuple(Parent, Scope,<br>
+ InlinedAt, false))<br>
+ .first;<br>
return &I->second;<br>
}<br>
<br>
<br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</blockquote></div><br></div></div>