Bug 1248534 (part 2) - Remove unused XPT flags. r=khuey.
authorNicholas Nethercote <nnethercote@mozilla.com>
Tue, 16 Feb 2016 19:04:18 +1100
changeset 321855 475874efad984c2141afd6818007f48846999d46
parent 321854 56f75a8f44915a4468fbedaf3beb9767b73eb343
child 321856 14ba54064f33d9dc0dbcdca7ebd2dff582973fcf
push id5913
push userjlund@mozilla.com
push dateMon, 25 Apr 2016 16:57:49 +0000
treeherdermozilla-beta@dcaf0a6fa115 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskhuey
bugs1248534
milestone47.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 1248534 (part 2) - Remove unused XPT flags. r=khuey.
xpcom/reflect/xptinfo/xptinfo.h
xpcom/typelib/xpt/xpt_struct.h
--- a/xpcom/reflect/xptinfo/xptinfo.h
+++ b/xpcom/reflect/xptinfo/xptinfo.h
@@ -182,17 +182,16 @@ class nsXPTMethodInfo : public XPTMethod
 // NO DATA - this a flyweight wrapper
 public:
     MOZ_IMPLICIT nsXPTMethodInfo(const XPTMethodDescriptor& desc)
         {*(XPTMethodDescriptor*)this = desc;}
 
     bool IsGetter()      const {return 0 != (XPT_MD_IS_GETTER(flags) );}
     bool IsSetter()      const {return 0 != (XPT_MD_IS_SETTER(flags) );}
     bool IsNotXPCOM()    const {return 0 != (XPT_MD_IS_NOTXPCOM(flags));}
-    bool IsConstructor() const {return 0 != (XPT_MD_IS_CTOR(flags)   );}
     bool IsHidden()      const {return 0 != (XPT_MD_IS_HIDDEN(flags) );}
     bool WantsOptArgc()  const {return 0 != (XPT_MD_WANTS_OPT_ARGC(flags));}
     bool WantsContext()  const {return 0 != (XPT_MD_WANTS_CONTEXT(flags));}
     const char* GetName()  const {return name;}
     uint8_t GetParamCount()  const {return num_args;}
     /* idx was index before I got _sick_ of the warnings on Unix, sorry jband */
     const nsXPTParamInfo GetParam(uint8_t idx) const
         {
--- a/xpcom/typelib/xpt/xpt_struct.h
+++ b/xpcom/typelib/xpt/xpt_struct.h
@@ -175,29 +175,22 @@ struct XPTString {
  * InterfaceIsTypeDescriptor.
  */
 
 /* why bother with a struct?  - other code relies on this being a struct */
 struct XPTTypeDescriptorPrefix {
     uint8_t flags;
 };
 
-/* flag bits -- fur and jband were right, I was miserably wrong */
-
-// THESE TWO FLAGS ARE DEPRECATED. DO NOT USE THEM. See bug 692342.
-#define XPT_TDP_POINTER          0x80
-#define XPT_TDP_REFERENCE        0x20
+/* flag bits */
 
 #define XPT_TDP_FLAGMASK         0xe0
 #define XPT_TDP_TAGMASK          (~XPT_TDP_FLAGMASK)
 #define XPT_TDP_TAG(tdp)         ((tdp).flags & XPT_TDP_TAGMASK)
 
-#define XPT_TDP_IS_POINTER(flags)        (flags & XPT_TDP_POINTER)
-#define XPT_TDP_IS_REFERENCE(flags)      (flags & XPT_TDP_REFERENCE)
-
 /* 
  * The following enum maps mnemonic names to the different numeric values 
  * of XPTTypeDescriptor->tag.
  */
 enum XPTTypeDescriptorTags {
     TD_INT8              = 0,
     TD_INT16             = 1,
     TD_INT32             = 2,
@@ -284,17 +277,17 @@ struct XPTConstDescriptor {
  * A ParamDescriptor is a variable-size record used to describe either a 
  * single argument to a method or a method's result.
  */
 struct XPTParamDescriptor {
     uint8_t           flags;
     XPTTypeDescriptor type;
 };
 
-/* flag bits -- jband and fur were right, and I was miserably wrong */
+/* flag bits */
 #define XPT_PD_IN       0x80
 #define XPT_PD_OUT      0x40
 #define XPT_PD_RETVAL   0x20
 #define XPT_PD_SHARED   0x10
 #define XPT_PD_DIPPER   0x08
 #define XPT_PD_OPTIONAL 0x04
 #define XPT_PD_FLAGMASK 0xfc
 
@@ -312,30 +305,28 @@ struct XPTParamDescriptor {
 struct XPTMethodDescriptor {
     char                *name;
     XPTParamDescriptor  *params;
     XPTParamDescriptor  result;
     uint8_t             flags;
     uint8_t             num_args;
 };
 
-/* flag bits -- jband and fur were right, and I was miserably wrong */
+/* flag bits */
 #define XPT_MD_GETTER   0x80
 #define XPT_MD_SETTER   0x40
 #define XPT_MD_NOTXPCOM 0x20
-#define XPT_MD_CTOR     0x10
 #define XPT_MD_HIDDEN   0x08
 #define XPT_MD_OPT_ARGC 0x04
 #define XPT_MD_CONTEXT  0x02
 #define XPT_MD_FLAGMASK 0xfe
 
 #define XPT_MD_IS_GETTER(flags)      (flags & XPT_MD_GETTER)
 #define XPT_MD_IS_SETTER(flags)      (flags & XPT_MD_SETTER)
 #define XPT_MD_IS_NOTXPCOM(flags)    (flags & XPT_MD_NOTXPCOM)
-#define XPT_MD_IS_CTOR(flags)        (flags & XPT_MD_CTOR)
 #define XPT_MD_IS_HIDDEN(flags)      (flags & XPT_MD_HIDDEN)
 #define XPT_MD_WANTS_OPT_ARGC(flags) (flags & XPT_MD_OPT_ARGC)
 #define XPT_MD_WANTS_CONTEXT(flags)  (flags & XPT_MD_CONTEXT)
 
 /*
  * Annotation records are variable-size records used to store secondary 
  * information about the typelib, e.g. such as the name of the tool that 
  * generated the typelib file, the date it was generated, etc.  The