<div dir="ltr">Reverted in r186255 for now.</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sat, Jul 13, 2013 at 11:54 AM, David Blaikie <span dir="ltr"><<a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote"><div class="im">On Sat, Jul 13, 2013 at 11:49 AM, Quentin Colombet <span dir="ltr"><<a href="mailto:qcolombet@apple.com" target="_blank">qcolombet@apple.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word">Hi David,<div><br></div><div>This breaks a buildbot:</div><div><a href="http://lab.llvm.org:8013/builders/clang-x86_64-darwin11-nobootstrap-RAincremental/builds/4351" target="_blank">http://lab.llvm.org:8013/builders/clang-x86_64-darwin11-nobootstrap-RAincremental/builds/4351</a></div>

</div></blockquote><div><br></div></div><div>Yes, I'm aware of the issue (it might help if buildcops such as yourself were on IRC for such things - bots report into the channel & a lot of live triage happens there for time-sensitive issues such as build breaks. It's a bit unnecessary to be sending email (when buildbots already send out failure mail anyway) when it's already being actively discussed)</div>
<div class="im">
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div><pre style="font-family:'Courier New',courier,monotype"><span>llvm[4]: Linking Release+Asserts unit test AST
</span><span style="color:red">Undefined symbols for architecture x86_64:
  "operator new[](unsigned long, clang::ASTContext const&, unsigned long)", referenced from:
      clang::ASTVector<int>::insert(clang::ASTContext&, int*, int const&) in ASTVectorTest.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[4]: *** [Release+Asserts/ASTTests] Error 1
make[3]: *** [AST/.makeall] Error 2
make[3]: *** Waiting for unfinished jobs....</span></pre><div>Could you fix it please?</div></div></div></blockquote><div><br></div></div><div>I'd love to, but having some trouble understanding how (short of reverting the patch, which I can do) - care to offer any insight on how this might be failing to link an inline function? (& this is building cleanly for me with CMake+Ninja)</div>
<div><div class="h5">
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div><div><br></div><div>Thanks,</div><div><br></div><div>-Quentin</div>
<div>
<div><div><div>On Jul 13, 2013, at 11:08 AM, David Blaikie <<a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a>> wrote:</div><br><blockquote type="cite">Author: dblaikie<br>Date: Sat Jul 13 13:08:59 2013<br>

New Revision: 186253<br><br>URL: <a href="http://llvm.org/viewvc/llvm-project?rev=186253&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=186253&view=rev</a><br>Log:<br>PR16540: ASTVector::insert(Context, Iter, Element) doesn't compile<br>

<br>Fix some uninstantiable code in ASTVector::insert. I've added a<br>cheap-and-dirty compile test for this, because I don't have the time to<br>figure out a nice way to get a real ASTContext to implement executable<br>

tests - but we probably should have them for this ADT.<br><br>Added:<br>    cfe/trunk/unittests/AST/ASTVectorTest.cpp<br>Modified:<br>    cfe/trunk/include/clang/AST/ASTVector.h<br>    cfe/trunk/unittests/AST/CMakeLists.txt<br>

<br>Modified: cfe/trunk/include/clang/AST/ASTVector.h<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/ASTVector.h?rev=186253&r1=186252&r2=186253&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/ASTVector.h?rev=186253&r1=186252&r2=186253&view=diff</a><br>

==============================================================================<br>--- cfe/trunk/include/clang/AST/ASTVector.h (original)<br>+++ cfe/trunk/include/clang/AST/ASTVector.h Sat Jul 13 13:08:59 2013<br>@@ -216,11 +216,11 @@ public:<br>

<br>   iterator insert(ASTContext &C, iterator I, const T &Elt) {<br>     if (I == this->end()) {  // Important special case for empty vector.<br>-      push_back(Elt);<br>+      push_back(Elt, C);<br>       return this->end()-1;<br>

     }<br><br>-    if (this->EndX < this->CapacityX) {<br>+    if (this->End < this->Capacity) {<br>     Retry:<br>       new (this->end()) T(this->back());<br>       this->setEnd(this->end()+1);<br>

<br>Added: cfe/trunk/unittests/AST/ASTVectorTest.cpp<br>URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/AST/ASTVectorTest.cpp?rev=186253&view=auto" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/AST/ASTVectorTest.cpp?rev=186253&view=auto</a><br>

==============================================================================<br>--- cfe/trunk/unittests/AST/ASTVectorTest.cpp (added)<br>+++ cfe/trunk/unittests/AST/ASTVectorTest.cpp Sat Jul 13 13:08:59 2013<br>@@ -0,0 +1,26 @@<br>

+//===- unittests/AST/DeclTest.cpp --- Declaration tests -------------------===//<br>+//<br>+//                     The LLVM Compiler Infrastructure<br>+//<br>+// This file is distributed under the University of Illinois Open Source<br>

+// License. See LICENSE.TXT for details.<br>+//<br>+//===----------------------------------------------------------------------===//<br>+//<br>+// Unit tests for the ASTVector container.<br>+//<br>+//===----------------------------------------------------------------------===//<br>

+<br>+#include "llvm/Support/Compiler.h"<br>+#include "clang/AST/ASTVector.h"<br>+#include "clang/Basic/TargetInfo.h"<br>+#include "clang/Frontend/CompilerInstance.h"<br>+#include "gtest/gtest.h"<br>

+<br>+using namespace clang;<br>+<br>+LLVM_ATTRIBUTE_UNUSED void CompileTest() {<br>+  ASTContext *C = 0;<br>+  ASTVector<int> V;<br>+  V.insert(*C, V.begin(), 0);<br>+}<br><br>Modified: cfe/trunk/unittests/AST/CMakeLists.txt<br>

URL: <a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/AST/CMakeLists.txt?rev=186253&r1=186252&r2=186253&view=diff" target="_blank">http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/AST/CMakeLists.txt?rev=186253&r1=186252&r2=186253&view=diff</a><br>

==============================================================================<br>--- cfe/trunk/unittests/AST/CMakeLists.txt (original)<br>+++ cfe/trunk/unittests/AST/CMakeLists.txt Sat Jul 13 13:08:59 2013<br>@@ -1,6 +1,7 @@<br>

 add_clang_unittest(ASTTests<br>   ASTContextParentMapTest.cpp<br>   ASTTypeTraitsTest.cpp<br>+  ASTVectorTest.cpp<br>   CommentLexer.cpp<br>   CommentParser.cpp<br>   DeclPrinterTest.cpp<br><br><br>_______________________________________________<br>

cfe-commits mailing list<br><a href="mailto:cfe-commits@cs.uiuc.edu" target="_blank">cfe-commits@cs.uiuc.edu</a><br><a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits</a><br>

</blockquote></div><br></div></div></div></div></blockquote></div></div></div><br></div></div>
</blockquote></div><br></div>