This is a patch to fix a compile error in STLExtras.h, and
authorChris Lattner <sabre@nondot.org>
Thu, 3 May 2007 18:32:10 +0000 (18:32 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 3 May 2007 18:32:10 +0000 (18:32 +0000)
a bug in GraphWriter.cpp.

Patch by Florian Brandner

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36684 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/ADT/STLExtras.h
lib/Support/GraphWriter.cpp

index af4996502fc7e631929f584a048d9c4fa49f3a8f..14137e3c1017e0ff6e13fb209ad2e9ff4b4b79be 100644 (file)
@@ -71,7 +71,7 @@ public:
   typedef RootIt iterator_type;
   typedef mapped_iterator<RootIt, UnaryFunc> _Self;
 
-  inline RootIt &getCurrent() const { return current; }
+  inline const RootIt &getCurrent() const { return current; }
 
   inline explicit mapped_iterator(const RootIt &I, UnaryFunc F)
     : current(I), Fn(F) {}
index 31d8d797bedbbb49c7335587d5a2b8ce021e7c99..eab76dff5d586f16938935c93d90d407223e147b 100644 (file)
@@ -70,6 +70,7 @@ void llvm::DisplayGraph(const sys::Path &Filename) {
   sys::Path dotty(LLVM_PATH_DOTTY);
 
   std::vector<const char*> args;
+  args.push_back(dotty.c_str());
   args.push_back(Filename.c_str());
   args.push_back(0);