Closed Bug 1444129 Opened 2 years ago Closed 2 years ago

Fix names of fields in xpt_struct.h

Categories

(Core :: XPCOM, enhancement)

enhancement
Not set

Tracking

()

RESOLVED FIXED
mozilla60
Tracking Status
firefox60 --- fixed

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(7 files)

These patches change the field names from foo_bar to mFooBar. I left alone  XPTTypeDescriptor.u and everything in XPTConstValue.
This is hopefully the last bit of major refactoring before bug 1438688.
Comment on attachment 8957325 [details]
Bug 1444129, part 1 - Rename fields of XPTHeader.

https://reviewboard.mozilla.org/r/226224/#review232176

+1 for modifying the names in comments!
Attachment #8957325 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957326 [details]
Bug 1444129, part 2 - Rename fields of XPTInterfaceDirectoryEntry.

https://reviewboard.mozilla.org/r/226226/#review232180
Attachment #8957326 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957327 [details]
Bug 1444129, part 3 - Rename XPTInterfaceDescriptor fields.

https://reviewboard.mozilla.org/r/226228/#review232182
Attachment #8957327 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957328 [details]
Bug 1444129, part 4 - Rename the one field of XPTTypeDescriptorPrefix.

https://reviewboard.mozilla.org/r/226230/#review232184
Attachment #8957328 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957329 [details]
Bug 1444129, part 5 - Rename fields of XPTTypeDescriptor and XPTConstDescriptor.

https://reviewboard.mozilla.org/r/226232/#review232186
Attachment #8957329 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957330 [details]
Bug 1444129, part 6 - Rename fields of XPTParamDescriptor.

https://reviewboard.mozilla.org/r/226234/#review232188
Attachment #8957330 - Flags: review?(n.nethercote) → review+
Comment on attachment 8957331 [details]
Bug 1444129, part 7 - Rename fields of XPTMethodDescriptor.

https://reviewboard.mozilla.org/r/226236/#review232190

::: xpcom/reflect/xptinfo/xptinfo.h:198
(Diff revision 1)
> -    bool IsNotXPCOM() const {return !!(flags & kNotXPCOMMask);}
> -    bool IsHidden() const {return !!(flags & kHiddenMask);}
> -    bool WantsOptArgc() const {return !!(flags & kOptArgcMask);}
> -    bool WantsContext() const {return !!(flags & kContextMask);}
> -    const char* GetName() const {return name;}
> -    uint8_t GetParamCount() const {return num_args;}
> +    bool IsNotXPCOM() const {return !!(mFlags & kNotXPCOMMask);}
> +    bool IsHidden() const {return !!(mFlags & kHiddenMask);}
> +    bool WantsOptArgc() const {return !!(mFlags & kOptArgcMask);}
> +    bool WantsContext() const {return !!(mFlags & kContextMask);}
> +    const char* GetName() const {return mName;}
> +    uint8_t GetParamCount() const {return mNumArgs;}

Bonus points if you add spaces around the braces of these one-liner functions.
Attachment #8957331 - Flags: review?(n.nethercote) → review+
(In reply to Nicholas Nethercote [:njn] from comment #15)
> Bonus points if you add spaces around the braces of these one-liner
> functions.

Done.
Pushed by amccreight@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/e1641b8d914d
part 1 - Rename fields of XPTHeader. r=njn
https://hg.mozilla.org/integration/autoland/rev/3e099aa442a9
part 2 - Rename fields of XPTInterfaceDirectoryEntry. r=njn
https://hg.mozilla.org/integration/autoland/rev/3f0758e1d897
part 3 - Rename XPTInterfaceDescriptor fields. r=njn
https://hg.mozilla.org/integration/autoland/rev/395189e8ad34
part 4 - Rename the one field of XPTTypeDescriptorPrefix. r=njn
https://hg.mozilla.org/integration/autoland/rev/de05343e7bd3
part 5 - Rename fields of XPTTypeDescriptor and XPTConstDescriptor. r=njn
https://hg.mozilla.org/integration/autoland/rev/be82df01da64
part 6 - Rename fields of XPTParamDescriptor. r=njn
https://hg.mozilla.org/integration/autoland/rev/4fdc36aa477a
part 7 - Rename fields of XPTMethodDescriptor. r=njn
You need to log in before you can comment on or make changes to this bug.