mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1084985 - Remove more 'using namespace JS;' to avoid sporadic bustage in unified builds (r=lth)
This commit is contained in:
parent
3e1da49fc6
commit
3ef4e824f5
@ -24,6 +24,9 @@ class Latin1Chars;
|
||||
class Latin1CharsZ;
|
||||
class ConstTwoByteChars;
|
||||
class TwoByteChars;
|
||||
class TwoByteCharsZ;
|
||||
class UTF8Chars;
|
||||
class UTF8CharsZ;
|
||||
|
||||
class AutoFunctionVector;
|
||||
class AutoIdVector;
|
||||
@ -70,6 +73,9 @@ using JS::Latin1Chars;
|
||||
using JS::Latin1CharsZ;
|
||||
using JS::ConstTwoByteChars;
|
||||
using JS::TwoByteChars;
|
||||
using JS::TwoByteCharsZ;
|
||||
using JS::UTF8Chars;
|
||||
using JS::UTF8CharsZ;
|
||||
|
||||
using JS::AutoFunctionVector;
|
||||
using JS::AutoIdVector;
|
||||
@ -132,6 +138,8 @@ using JS::MutableHandleValue;
|
||||
|
||||
using JS::NullHandleValue;
|
||||
using JS::UndefinedHandleValue;
|
||||
using JS::TrueHandleValue;
|
||||
using JS::FalseHandleValue;
|
||||
|
||||
using JS::HandleValueArray;
|
||||
|
||||
|
@ -39,7 +39,6 @@
|
||||
#include "vm/NativeObject-inl.h"
|
||||
|
||||
using namespace js;
|
||||
using namespace JS;
|
||||
|
||||
using mozilla::ArrayLength;
|
||||
using mozilla::Move;
|
||||
@ -251,12 +250,12 @@ GC(JSContext *cx, unsigned argc, jsval *vp)
|
||||
if (compartment)
|
||||
PrepareForDebugGC(cx->runtime());
|
||||
else
|
||||
PrepareForFullGC(cx->runtime());
|
||||
JS::PrepareForFullGC(cx->runtime());
|
||||
|
||||
if (shrinking)
|
||||
ShrinkingGC(cx->runtime(), gcreason::API);
|
||||
JS::ShrinkingGC(cx->runtime(), JS::gcreason::API);
|
||||
else
|
||||
GCForReason(cx->runtime(), gcreason::API);
|
||||
JS::GCForReason(cx->runtime(), JS::gcreason::API);
|
||||
|
||||
char buf[256] = { '\0' };
|
||||
#ifndef JS_MORE_DETERMINISTIC
|
||||
@ -278,7 +277,7 @@ MinorGC(JSContext *cx, unsigned argc, jsval *vp)
|
||||
if (args.get(0) == BooleanValue(true))
|
||||
cx->runtime()->gc.storeBuffer.setAboutToOverflow();
|
||||
|
||||
cx->minorGC(gcreason::API);
|
||||
cx->minorGC(JS::gcreason::API);
|
||||
#endif
|
||||
args.rval().setUndefined();
|
||||
return true;
|
||||
@ -349,7 +348,7 @@ GCParameter(JSContext *cx, unsigned argc, Value *vp)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (param == JSGC_MARK_STACK_LIMIT && IsIncrementalGCInProgress(cx->runtime())) {
|
||||
if (param == JSGC_MARK_STACK_LIMIT && JS::IsIncrementalGCInProgress(cx->runtime())) {
|
||||
JS_ReportError(cx, "attempt to set markStackLimit while a GC is in progress");
|
||||
return false;
|
||||
}
|
||||
|
@ -18,7 +18,6 @@
|
||||
#include "vm/NativeObject-inl.h"
|
||||
|
||||
using namespace js;
|
||||
using namespace JS;
|
||||
|
||||
const Class WeakSetObject::class_ = {
|
||||
"WeakSet",
|
||||
@ -73,7 +72,7 @@ WeakSetObject::create(JSContext *cx)
|
||||
if (!obj)
|
||||
return nullptr;
|
||||
|
||||
RootedObject map(cx, NewWeakMapObject(cx));
|
||||
RootedObject map(cx, JS::NewWeakMapObject(cx));
|
||||
if (!map)
|
||||
return nullptr;
|
||||
|
||||
@ -99,7 +98,7 @@ WeakSetObject::construct(JSContext *cx, unsigned argc, Value *vp)
|
||||
if (args.hasDefined(0)) {
|
||||
RootedObject map(cx, &obj->getReservedSlot(WEAKSET_MAP_SLOT).toObject());
|
||||
|
||||
ForOfIterator iter(cx);
|
||||
JS::ForOfIterator iter(cx);
|
||||
if (!iter.init(args[0]))
|
||||
return false;
|
||||
|
||||
|
@ -33,7 +33,6 @@
|
||||
#include "vm/ScopeObject-inl.h"
|
||||
|
||||
using namespace js;
|
||||
using namespace JS;
|
||||
|
||||
using mozilla::Move;
|
||||
using mozilla::PodArrayZero;
|
||||
@ -1094,13 +1093,13 @@ JS::WasIncrementalGC(JSRuntime *rt)
|
||||
}
|
||||
|
||||
char16_t *
|
||||
GCDescription::formatMessage(JSRuntime *rt) const
|
||||
JS::GCDescription::formatMessage(JSRuntime *rt) const
|
||||
{
|
||||
return rt->gc.stats.formatMessage();
|
||||
}
|
||||
|
||||
char16_t *
|
||||
GCDescription::formatJSON(JSRuntime *rt, uint64_t timestamp) const
|
||||
JS::GCDescription::formatJSON(JSRuntime *rt, uint64_t timestamp) const
|
||||
{
|
||||
return rt->gc.stats.formatJSON(timestamp);
|
||||
}
|
||||
|
@ -8,7 +8,8 @@
|
||||
#include "jscntxt.h" /* for error messages */
|
||||
#include "jsobj.h" /* for unwrapping without a context */
|
||||
|
||||
using namespace JS;
|
||||
using namespace js;
|
||||
using JS::PerfMeasurement;
|
||||
|
||||
// You cannot forward-declare a static object in C++, so instead
|
||||
// we have to forward-declare the helper function that refers to it.
|
||||
|
@ -11,7 +11,7 @@
|
||||
#include "jscntxt.h"
|
||||
#include "jsprf.h"
|
||||
|
||||
using namespace JS;
|
||||
using namespace js;
|
||||
|
||||
Latin1CharsZ
|
||||
JS::LossyTwoByteCharsToNewLatin1CharsZ(js::ThreadSafeContext *cx,
|
||||
@ -293,7 +293,7 @@ InflateUTF8StringToBuffer(JSContext *cx, const UTF8Chars src, char16_t *dst, siz
|
||||
INVALID(ReportInvalidCharacter, i, m);
|
||||
|
||||
// Determine the code unit's length in char16_t and act accordingly.
|
||||
v = Utf8ToOneUcs4Char((uint8_t *)&src[i], n);
|
||||
v = JS::Utf8ToOneUcs4Char((uint8_t *)&src[i], n);
|
||||
if (v < 0x10000) {
|
||||
// The n-byte UTF8 code unit will fit in a single char16_t.
|
||||
if (action == Copy)
|
||||
|
Loading…
Reference in New Issue
Block a user