Bug 1429904 - Make FrameKey members const. r?njn draft
authorMarkus Stange <mstange@themasta.com>
Tue, 27 Feb 2018 23:11:34 -0500
changeset 762102 bf93be38d9f6caaa414df5c517ae223bcf131ef5
parent 762101 5ab6d98acb6a6624c841839de838c3bc470e8631
child 762103 d8b516a654c4d4ed73dd10ee308080db728c5f44
push id101088
push userbmo:mstange@themasta.com
push dateThu, 01 Mar 2018 20:52:26 +0000
reviewersnjn
bugs1429904
milestone60.0a1
Bug 1429904 - Make FrameKey members const. r?njn MozReview-Commit-ID: KTYmCJM9tOH
tools/profiler/core/ProfileBufferEntry.h
--- a/tools/profiler/core/ProfileBufferEntry.h
+++ b/tools/profiler/core/ProfileBufferEntry.h
@@ -167,21 +167,21 @@ public:
       return mAddress == aRhs.mAddress && mStreamingGen == aRhs.mStreamingGen;
     }
     bool operator!=(const JITAddress& aRhs) const { return !(*this == aRhs); }
   };
 
   struct FrameKey {
     // This cannot be a std::string, as it is not memmove compatible, which
     // is used by nsHashTable
-    nsCString mLocation;
-    mozilla::Maybe<unsigned> mLine;
-    mozilla::Maybe<unsigned> mCategory;
-    mozilla::Maybe<JITAddress> mJITAddress;
-    mozilla::Maybe<uint32_t> mJITDepth;
+    const nsCString mLocation;
+    const mozilla::Maybe<unsigned> mLine;
+    const mozilla::Maybe<unsigned> mCategory;
+    const mozilla::Maybe<JITAddress> mJITAddress;
+    const mozilla::Maybe<uint32_t> mJITDepth;
 
     explicit FrameKey(const char* aLocation)
      : mLocation(aLocation)
     {
     }
 
     FrameKey(const char* aLocation, const mozilla::Maybe<unsigned>& aLine,
              const mozilla::Maybe<unsigned>& aCategory)