r355036 - [clang][index-while-building][NFC] FileIndexRecord - Comments, replace auto with type

Jan Korous via cfe-commits cfe-commits at lists.llvm.org
Wed Feb 27 13:48:02 PST 2019


Author: jkorous
Date: Wed Feb 27 13:48:02 2019
New Revision: 355036

URL: http://llvm.org/viewvc/llvm-project?rev=355036&view=rev
Log:
[clang][index-while-building][NFC] FileIndexRecord - Comments, replace auto with type

Differential Revision: https://reviews.llvm.org/D58478

Modified:
    cfe/trunk/include/clang/Index/DeclOccurrence.h
    cfe/trunk/lib/Index/FileIndexRecord.cpp
    cfe/trunk/lib/Index/FileIndexRecord.h

Modified: cfe/trunk/include/clang/Index/DeclOccurrence.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Index/DeclOccurrence.h?rev=355036&r1=355035&r2=355036&view=diff
==============================================================================
--- cfe/trunk/include/clang/Index/DeclOccurrence.h (original)
+++ cfe/trunk/include/clang/Index/DeclOccurrence.h Wed Feb 27 13:48:02 2019
@@ -1,9 +1,8 @@
-//===--- DeclOccurrence.h - An occurrence of a decl within a file ---------===//
+//===- DeclOccurrence.h - An occurrence of a decl within a file -*- C++ -*-===//
 //
-//                     The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 //
 //===----------------------------------------------------------------------===//
 
@@ -39,4 +38,4 @@ struct DeclOccurrence {
 } // namespace index
 } // namespace clang
 
-#endif
+#endif // LLVM_CLANG_INDEX_DECLOCCURRENCE_H

Modified: cfe/trunk/lib/Index/FileIndexRecord.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Index/FileIndexRecord.cpp?rev=355036&r1=355035&r2=355036&view=diff
==============================================================================
--- cfe/trunk/lib/Index/FileIndexRecord.cpp (original)
+++ cfe/trunk/lib/Index/FileIndexRecord.cpp Wed Feb 27 13:48:02 2019
@@ -1,4 +1,4 @@
-//===--- FileIndexRecord.cpp - Index data per file ------------------------===//
+//===--- FileIndexRecord.cpp - Index data per file --------------*- C++ -*-===//
 //
 //                     The LLVM Compiler Infrastructure
 //
@@ -42,7 +42,7 @@ void FileIndexRecord::addDeclOccurence(S
 void FileIndexRecord::print(llvm::raw_ostream &OS) const {
   OS << "DECLS BEGIN ---\n";
   for (auto &DclInfo : Decls) {
-    auto D = DclInfo.Dcl;
+    const Decl *D = DclInfo.Dcl;
     SourceManager &SM = D->getASTContext().getSourceManager();
     SourceLocation Loc = SM.getFileLoc(D->getLocation());
     PresumedLoc PLoc = SM.getPresumedLoc(Loc);

Modified: cfe/trunk/lib/Index/FileIndexRecord.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Index/FileIndexRecord.h?rev=355036&r1=355035&r2=355036&view=diff
==============================================================================
--- cfe/trunk/lib/Index/FileIndexRecord.h (original)
+++ cfe/trunk/lib/Index/FileIndexRecord.h Wed Feb 27 13:48:02 2019
@@ -1,9 +1,8 @@
-//===--- FileIndexRecord.h - Index data per file --------------------------===//
+//===--- FileIndexRecord.h - Index data per file ----------------*- C++ -*-===//
 //
-//                     The LLVM Compiler Infrastructure
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
+// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
+// See https://llvm.org/LICENSE.txt for license information.
+// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 //
 //===----------------------------------------------------------------------===//
 
@@ -55,4 +54,4 @@ public:
 } // end namespace index
 } // end namespace clang
 
-#endif
+#endif // LLVM_CLANG_LIB_INDEX_FILEINDEXRECORD_H




More information about the cfe-commits mailing list