forked from mirrors/gecko-dev
Bug 555727: Stop MSVC from over-optimizing NS_DECLARE_FRAME_PROPERTY. r=dbaron
This commit is contained in:
parent
8015c79acc
commit
3387c15d67
1 changed files with 10 additions and 0 deletions
|
|
@ -824,11 +824,21 @@ public:
|
|||
delete static_cast<nsPoint*>(aPropertyValue);
|
||||
}
|
||||
|
||||
#ifdef _MSC_VER
|
||||
// XXX Workaround MSVC issue by making the static FramePropertyDescriptor
|
||||
// non-const. See bug 555727.
|
||||
#define NS_DECLARE_FRAME_PROPERTY(prop, dtor) \
|
||||
static const FramePropertyDescriptor* prop() { \
|
||||
static FramePropertyDescriptor descriptor = { dtor }; \
|
||||
return &descriptor; \
|
||||
}
|
||||
#else
|
||||
#define NS_DECLARE_FRAME_PROPERTY(prop, dtor) \
|
||||
static const FramePropertyDescriptor* prop() { \
|
||||
static const FramePropertyDescriptor descriptor = { dtor }; \
|
||||
return &descriptor; \
|
||||
}
|
||||
#endif
|
||||
|
||||
NS_DECLARE_FRAME_PROPERTY(IBSplitSpecialSibling, nsnull)
|
||||
NS_DECLARE_FRAME_PROPERTY(IBSplitSpecialPrevSibling, nsnull)
|
||||
|
|
|
|||
Loading…
Reference in a new issue