Closed
Bug 870959
Opened 12 years ago
Closed 12 years ago
don't include Preferences.h or NonRefcountedDOMObject.h in bindings unless necessary
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla23
People
(Reporter: froydnj, Unassigned)
Details
Attachments
(1 file)
3.59 KB,
patch
|
bzbarsky
:
review+
|
Details | Diff | Splinter Review |
No description provided.
![]() |
Reporter | |
Comment 1•12 years ago
|
||
Attachment #748166 -
Flags: review?(bzbarsky)
![]() |
||
Comment 2•12 years ago
|
||
Comment on attachment 748166 [details] [diff] [review]
don't include Preferences.h or NonRefcountedDOMObject.h in bindings unless necessary
>+ def descriptorRequiresPreferences(desc):
I think I'd prefer this function to look like this:
iface = desc.iface
return any(m.getExtendedAttribute("Pref") for m in iface.members + [iface])
In particular, you shouldn't need Preferences.h for a [Func] on a member, I don't think, nor for [PrefControlled] on an interface.
>+ requiresPreferences = any(map(descriptorRequiresPreferences, descriptors))
I'd prefer any(descriptorRequiresPreferences(d) for d in descriptors) so it can stop once it finds one...
>+ hasNativeOwnership = any(map(lambda d: d.nativeOwnership == 'owned',
How about calling that variable hasOwnedDescriptors?
And again, any(d.nativeOwnership == 'owned' for d in descriptors).
r=me
hasNativeOwnership = any(
Attachment #748166 -
Flags: review?(bzbarsky) → review+
![]() |
Reporter | |
Comment 3•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla23
Assignee | ||
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•