Bug 1264830 - Part 4: Change nsStyleDisplay::mWillChange to use nsTArray. r=bholley
authorCameron McCormack <cam@mcc.id.au>
Tue, 19 Apr 2016 09:51:16 +1000
changeset 331554 bb030d6a1d9f0e6d79774340d9ea09788c9fda30
parent 331553 725e1fb867eb588b658ec47354803dfb82c971b7
child 331555 167c5e5e4b5c539b6db9b030ea2aaa2b5bccdd8b
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbholley
bugs1264830
milestone48.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 1264830 - Part 4: Change nsStyleDisplay::mWillChange to use nsTArray. r=bholley The initial value of nsStyleDisplay::mWillChange is represented by an empty array, and will-change is not so common, so we change it to use an nsTArray.
layout/style/nsStyleStruct.h
--- a/layout/style/nsStyleStruct.h
+++ b/layout/style/nsStyleStruct.h
@@ -2545,17 +2545,17 @@ struct nsStyleDisplay
   uint8_t mIsolation;           // [reset] see nsStyleConsts.h
   uint8_t mTopLayer;            // [reset] see nsStyleConsts.h
   uint8_t mWillChangeBitField;  // [reset] see nsStyleConsts.h. Stores a
                                 // bitfield representation of the properties
                                 // that are frequently queried. This should
                                 // match mWillChange. Also tracks if any of the
                                 // properties in the will-change list require
                                 // a stacking context.
-  AutoTArray<nsString, 1> mWillChange;
+  nsTArray<nsString> mWillChange;
 
   uint8_t mTouchAction;         // [reset] see nsStyleConsts.h
   uint8_t mScrollBehavior;      // [reset] see nsStyleConsts.h NS_STYLE_SCROLL_BEHAVIOR_*
   uint8_t mScrollSnapTypeX;     // [reset] see nsStyleConsts.h NS_STYLE_SCROLL_SNAP_TYPE_*
   uint8_t mScrollSnapTypeY;     // [reset] see nsStyleConsts.h NS_STYLE_SCROLL_SNAP_TYPE_*
   nsStyleCoord mScrollSnapPointsX; // [reset]
   nsStyleCoord mScrollSnapPointsY; // [reset]
   Position mScrollSnapDestination; // [reset]