Bug 1216386 - Improve AnimatedGeometryRootLookup::Hash. r=roc.
authorNicholas Nethercote <nnethercote@mozilla.com>
Mon, 19 Oct 2015 19:57:47 -0700
changeset 303627 fa1abcf44453ef605a4e1b33cc5e99879a35af32
parent 303626 551ecd4bb718f7f2d00df8716a143ac4f43d0dca
child 303628 4d203aca24e3a471ab627fd5d919612ea9ab0e35
push id1001
push userraliiev@mozilla.com
push dateMon, 18 Jan 2016 19:06:03 +0000
treeherdermozilla-release@8b89261f3ac4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersroc
bugs1216386
milestone44.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1216386 - Improve AnimatedGeometryRootLookup::Hash. r=roc. When someone types |sizeof(this)| they usually want |sizeof(*this)|.
layout/base/nsDisplayList.h
--- a/layout/base/nsDisplayList.h
+++ b/layout/base/nsDisplayList.h
@@ -1108,17 +1108,17 @@ private:
 
     AnimatedGeometryRootLookup(const nsIFrame* aFrame, const nsIFrame* aStopAtFrame)
       : mFrame(aFrame)
       , mStopAtFrame(aStopAtFrame)
     {
     }
 
     PLDHashNumber Hash() const {
-      return mozilla::HashBytes(this, sizeof(this));
+      return mozilla::HashBytes(this, sizeof(*this));
     }
 
     bool operator==(const AnimatedGeometryRootLookup& aOther) const {
       return mFrame == aOther.mFrame && mStopAtFrame == aOther.mStopAtFrame;
     }
   };
   // Cache for storing animated geometry roots for arbitrary frames
   nsDataHashtable<nsGenericHashKey<AnimatedGeometryRootLookup>, nsIFrame*>