mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 903543 - eliminate static constructors from SMIL types (and destructors, in opt builds); r=dholbert
This commit is contained in:
parent
71abcfec30
commit
9ebfa27137
@ -42,8 +42,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SMILBoolType() {}
|
MOZ_CONSTEXPR SMILBoolType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SMILBoolType() {}
|
~SMILBoolType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -43,8 +43,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SMILEnumType() {}
|
MOZ_CONSTEXPR SMILEnumType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SMILEnumType() {}
|
~SMILEnumType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -37,7 +37,10 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
SMILIntegerType() {}
|
MOZ_CONSTEXPR SMILIntegerType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
|
~SMILIntegerType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -43,8 +43,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SMILStringType() {}
|
MOZ_CONSTEXPR SMILStringType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SMILStringType() {}
|
~SMILStringType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -6,6 +6,7 @@
|
|||||||
#ifndef NS_ISMILTYPE_H_
|
#ifndef NS_ISMILTYPE_H_
|
||||||
#define NS_ISMILTYPE_H_
|
#define NS_ISMILTYPE_H_
|
||||||
|
|
||||||
|
#include "mozilla/Attributes.h"
|
||||||
#include "nscore.h"
|
#include "nscore.h"
|
||||||
|
|
||||||
class nsSMILValue;
|
class nsSMILValue;
|
||||||
@ -212,8 +213,17 @@ protected:
|
|||||||
* Protected destructor, to ensure that no one accidentally deletes an
|
* Protected destructor, to ensure that no one accidentally deletes an
|
||||||
* instance of this class.
|
* instance of this class.
|
||||||
* (The only instances in existence should be singletons - one per subclass.)
|
* (The only instances in existence should be singletons - one per subclass.)
|
||||||
|
*
|
||||||
|
* This destructor and the destructors of subclasses are only defined in
|
||||||
|
* debug builds. For non-debug builds, we let the compiler define the
|
||||||
|
* default (public) constructor. The compiler understands that the default
|
||||||
|
* destructor doesn't necessarily need to be invoked (e.g. if there are no
|
||||||
|
* members to destroy) and so will avoid creating static destructors (and
|
||||||
|
* registering them with static *constructors*) in non-debug builds.
|
||||||
*/
|
*/
|
||||||
|
#ifdef DEBUG
|
||||||
~nsISMILType() {}
|
~nsISMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // NS_ISMILTYPE_H_
|
#endif // NS_ISMILTYPE_H_
|
||||||
|
@ -100,8 +100,10 @@ public:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
nsSMILCSSValueType() {}
|
MOZ_CONSTEXPR nsSMILCSSValueType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~nsSMILCSSValueType() {}
|
~nsSMILCSSValueType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // NS_SMILCSSVALUETYPE_H_
|
#endif // NS_SMILCSSVALUETYPE_H_
|
||||||
|
@ -41,8 +41,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
nsSMILFloatType() {}
|
MOZ_CONSTEXPR nsSMILFloatType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~nsSMILFloatType() {}
|
~nsSMILFloatType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // NS_SMILFLOATTYPE_H_
|
#endif // NS_SMILFLOATTYPE_H_
|
||||||
|
@ -44,8 +44,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
nsSMILNullType() {}
|
MOZ_CONSTEXPR nsSMILNullType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~nsSMILNullType() {}
|
~nsSMILNullType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // NS_SMILNULLTYPE_H_
|
#endif // NS_SMILNULLTYPE_H_
|
||||||
|
@ -45,8 +45,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGIntegerPairSMILType() {}
|
MOZ_CONSTEXPR SVGIntegerPairSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGIntegerPairSMILType() {}
|
~SVGIntegerPairSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -93,8 +93,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGLengthListSMILType() {}
|
MOZ_CONSTEXPR SVGLengthListSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGLengthListSMILType() {}
|
~SVGLengthListSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -73,8 +73,10 @@ public:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGMotionSMILType() {}
|
MOZ_CONSTEXPR SVGMotionSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGMotionSMILType() {}
|
~SVGMotionSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -47,8 +47,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGNumberListSMILType() {}
|
MOZ_CONSTEXPR SVGNumberListSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGNumberListSMILType() {}
|
~SVGNumberListSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -40,8 +40,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGNumberPairSMILType() {}
|
MOZ_CONSTEXPR SVGNumberPairSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGNumberPairSMILType() {}
|
~SVGNumberPairSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -60,8 +60,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGOrientSMILType() {}
|
MOZ_CONSTEXPR SVGOrientSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGOrientSMILType() {}
|
~SVGOrientSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -51,8 +51,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGPathSegListSMILType() {}
|
MOZ_CONSTEXPR SVGPathSegListSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGPathSegListSMILType() {}
|
~SVGPathSegListSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -47,8 +47,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGPointListSMILType() {}
|
MOZ_CONSTEXPR SVGPointListSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGPointListSMILType() {}
|
~SVGPointListSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
@ -123,8 +123,10 @@ public:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGTransformListSMILType() {}
|
MOZ_CONSTEXPR SVGTransformListSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGTransformListSMILType() {}
|
~SVGTransformListSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end namespace mozilla
|
} // end namespace mozilla
|
||||||
|
@ -40,8 +40,10 @@ protected:
|
|||||||
private:
|
private:
|
||||||
// Private constructor & destructor: prevent instances beyond my singleton,
|
// Private constructor & destructor: prevent instances beyond my singleton,
|
||||||
// and prevent others from deleting my singleton.
|
// and prevent others from deleting my singleton.
|
||||||
SVGViewBoxSMILType() {}
|
MOZ_CONSTEXPR SVGViewBoxSMILType() {}
|
||||||
|
#ifdef DEBUG
|
||||||
~SVGViewBoxSMILType() {}
|
~SVGViewBoxSMILType() {}
|
||||||
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
} // namespace mozilla
|
} // namespace mozilla
|
||||||
|
Loading…
Reference in New Issue
Block a user