Fix previous commit and fully remove variable.
[oota-llvm.git] / lib / IR / GCOV.cpp
index a91e88c4e0f8bf1b5a892ec686ed26ea3335bc2c..f0f8c7d74bb914458e7afe7724958d34c06bb4b4 100644 (file)
@@ -7,7 +7,7 @@
 //
 //===----------------------------------------------------------------------===//
 //
-// GCOV implements the interface to read and write coverage files that use 
+// GCOV implements the interface to read and write coverage files that use
 // 'gcov' format.
 //
 //===----------------------------------------------------------------------===//
@@ -94,7 +94,7 @@ void GCOVFile::dump() {
 /// reading .gcno and .gcda files.
 void GCOVFile::collectLineCounts(FileInfo &FI) {
   for (SmallVectorImpl<GCOVFunction *>::iterator I = Functions.begin(),
-         E = Functions.end(); I != E; ++I) 
+         E = Functions.end(); I != E; ++I)
     (*I)->collectLineCounts(FI);
   FI.setRunCount(RunCount);
   FI.setProgramCount(ProgramCount);
@@ -292,14 +292,14 @@ void FileInfo::print(raw_fd_ostream &OS, StringRef gcnoFile,
       errs() << Filename << ": " << ec.message() << "\n";
       return;
     }
-    StringRef AllLines = Buff.take()->getBuffer();
+    StringRef AllLines = Buff->getBuffer();
     uint32_t i = 0;
     while (!AllLines.empty()) {
       if (L.find(i) != L.end()) {
         if (L[i] == 0)
           OS << "    #####:";
         else
-          OS << format("%9lu:", L[i]);
+          OS << format("%9" PRIu64 ":", L[i]);
       } else {
         OS << "        -:";
       }
@@ -312,4 +312,3 @@ void FileInfo::print(raw_fd_ostream &OS, StringRef gcnoFile,
     }
   }
 }
-