[llvm] r332475 - [ThinLTO] Add const qualifier to a couple of flag getter methods

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Wed May 16 07:56:03 PDT 2018


Author: tejohnson
Date: Wed May 16 07:56:02 2018
New Revision: 332475

URL: http://llvm.org/viewvc/llvm-project?rev=332475&view=rev
Log:
[ThinLTO] Add const qualifier to a couple of flag getter methods

Split these minor fixes out of D46699.

Modified:
    llvm/trunk/include/llvm/IR/ModuleSummaryIndex.h

Modified: llvm/trunk/include/llvm/IR/ModuleSummaryIndex.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/IR/ModuleSummaryIndex.h?rev=332475&r1=332474&r2=332475&view=diff
==============================================================================
--- llvm/trunk/include/llvm/IR/ModuleSummaryIndex.h (original)
+++ llvm/trunk/include/llvm/IR/ModuleSummaryIndex.h Wed May 16 07:56:02 2018
@@ -312,7 +312,7 @@ public:
   StringRef modulePath() const { return ModulePath; }
 
   /// Get the flags for this GlobalValue (see \p struct GVFlags).
-  GVFlags flags() { return Flags; }
+  GVFlags flags() const { return Flags; }
 
   /// Return linkage type recorded for this global value.
   GlobalValue::LinkageTypes linkage() const {
@@ -516,7 +516,7 @@ public:
   }
 
   /// Get function attribute flags.
-  FFlags &fflags() { return FunFlags; }
+  FFlags fflags() const { return FunFlags; }
 
   /// Get the instruction count recorded for this function.
   unsigned instCount() const { return InstCount; }




More information about the llvm-commits mailing list