Closed Bug 1290320 Opened 9 years ago Closed 9 years ago

Add missing include to nsStyleSet.h

Categories

(Core :: Layout, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla50
Tracking Status
firefox50 --- fixed

People

(Reporter: jyc, Assigned: jyc)

Details

Attachments

(1 file)

nsStyleSet.h is missing an include of StyleSheetHandleInlines.h. I get the following error on my local build (didn't have it before, but it's exposed after I added a file to the unified sources): 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/layout/style/Unified_cpp_layout_style4.cpp:2: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/layout/style/nsStyleSet.cpp:12: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/layout/style/nsStyleSet.h:16: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/CSSStyleSheet.h:15: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/StyleSheet.h:12: 0:16.51 /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/StyleSheetHandle.h:99:36: error: inline function 'mozilla::StyleSheetHandle::Ptr::AddRef' is not defined [-Werror,-Wundefined-inline] 0:16.51 inline MozExternalRefCountType AddRef(); 0:16.51 ^ 0:16.51 /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/HandleRefPtr.h:87:13: note: used here 0:16.51 aPtr->AddRef(); 0:16.51 ^ 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/layout/style/Unified_cpp_layout_style4.cpp:2: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/layout/style/nsStyleSet.cpp:12: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/layout/style/nsStyleSet.h:16: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/CSSStyleSheet.h:15: 0:16.51 In file included from /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/StyleSheet.h:12: 0:16.51 /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/StyleSheetHandle.h:100:36: error: inline function 'mozilla::StyleSheetHandle::Ptr::Release' is not defined [-Werror,-Wundefined-inline] 0:16.51 inline MozExternalRefCountType Release(); 0:16.51 ^ 0:16.51 /Users/jchan/projects/mozilla-central/obj-x86_64-apple-darwin15.6.0/dist/include/mozilla/HandleRefPtr.h:98:13: note: used here 0:16.51 aPtr->Release(); 0:16.51 ^ 0:16.51 2 errors generated.
Comment on attachment 8775818 [details] Bug 1290320 - Add missing include to nsStyleSet.h. https://reviewboard.mozilla.org/r/67872/#review64932 Generally FooInlines.h should only be included by cpp files, not .h files. Is there a reason this needs to be included by nsStyleSet.h rather than nsStyleSet.cpp? Also, please keep includes sorted alphabetically when they are already. ::: layout/style/nsStyleSet.h:17 (Diff revision 1) > #ifndef nsStyleSet_h_ > #define nsStyleSet_h_ > > #include "mozilla/Attributes.h" > #include "mozilla/CSSStyleSheet.h" > +#include "mozilla/StyleSheetHandleInlines.h"
Attachment #8775818 - Flags: review?(bobbyholley) → review-
https://reviewboard.mozilla.org/r/67872/#review64932 No reason, looks like moving it to nsStyleSet.cpp also fixes the problem. Tried to put it directly next to it as the other includes of StyleSheetHandler had it. Moving to .cpp and putting alphabetically, thanks.
Comment on attachment 8775818 [details] Bug 1290320 - Add missing include to nsStyleSet.h. Review request updated; see interdiff: https://reviewboard.mozilla.org/r/67872/diff/1-2/
Attachment #8775818 - Flags: review- → review?(bobbyholley)
Comment on attachment 8775818 [details] Bug 1290320 - Add missing include to nsStyleSet.h. https://reviewboard.mozilla.org/r/67872/#review64944 thanks!
Attachment #8775818 - Flags: review?(bobbyholley) → review+
Keywords: checkin-needed
Pushed by bholley@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d90fb87dd045 Add missing include to nsStyleSet.h. r=bholley
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla50
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: