зеркало из https://github.com/mozilla/pjs.git
Bug 609248 - Move SameType outside js::Value as a workaround to gcc PR/38850. r=lw,a=shaver
This commit is contained in:
Родитель
51e512944e
Коммит
a501d238e1
|
@ -566,10 +566,10 @@ class Value
|
|||
return data.asBits != rhs.data.asBits;
|
||||
}
|
||||
|
||||
JS_ALWAYS_INLINE
|
||||
friend bool SameType(const Value &lhs, const Value &rhs) {
|
||||
return JSVAL_SAME_TYPE_IMPL(lhs.data, rhs.data);
|
||||
}
|
||||
/* This function used to be inlined here, but this triggered a gcc bug
|
||||
due to SameType being used in a template method.
|
||||
See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38850 */
|
||||
friend bool SameType(const Value &lhs, const Value &rhs);
|
||||
|
||||
/*** Extract the value's typed payload ***/
|
||||
|
||||
|
@ -740,6 +740,12 @@ class Value
|
|||
jsval_layout data;
|
||||
} JSVAL_ALIGNMENT;
|
||||
|
||||
JS_ALWAYS_INLINE bool
|
||||
SameType(const Value &lhs, const Value &rhs)
|
||||
{
|
||||
return JSVAL_SAME_TYPE_IMPL(lhs.data, rhs.data);
|
||||
}
|
||||
|
||||
static JS_ALWAYS_INLINE Value
|
||||
NullValue()
|
||||
{
|
||||
|
|
Загрузка…
Ссылка в новой задаче