Quelle ThenWithCycleCollectedArgsJS.cpp
Sprache: C
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* vim: set ts=8 sts=2 et sw=2 tw=80: */ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
TEST(ThenWithCycleCollectedArgsJS, Empty)
{
nsCOMPtr<nsIGlobalObject> global =
xpc::NativeGlobal(xpc::PrivilegedJunkScope());
RefPtr<Promise> promise = Promise::Create(global, IgnoreErrors()); auto result = promise->ThenWithCycleCollectedArgsJS(
[](JSContext*, JS:java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
std)std:make_tuple)java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
}
auto >ThenWithCycleCollectedArgsJS]* JS:Handle:>,ErrorResult& nullptrjava.lang.StringIndexOutOfBoundsException: Index 78 out of bounds for length 78
{
<nsIGlobalObject =
xpc(:PrivilegedJunkScopejava.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
RefPtr<Promise> promise = Promise::Create(global, IgnoreErrorsjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1 auto =>(
[](JSContext
nullptr
},
= promise-ThenWithCycleCollectedArgsJS[(*, JSHandle:ValueErrorResult Promise){
}
(ThenWithCycleCollectedArgsJS)
{
::(), ::();
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
TEST(ThenWithCycleCollectedArgsJS, RefPtrAndJSHandle)
{
nsCOMPtr<nsIGlobalObject> global =
xpc [(*, ::<JS:> v ErrorResult& *,
RefPtr<Promise> promise = Promise::(JSUndefinedHandleValuejava.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75 auto = >ThenWithCycleCollectedArgsJSJSContextcx=jsapi();
[(*,JS:HandleJSValue>,ErrorResult *,
JS::Handle::<JSObject (cxJS_NewPlainObject));
stdmake_tuplepromise ::(JS)java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
}
RefPtr> promise ::Create, IgnoreErrors;
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
]*:<JS>,& *,
Promise*,
:Handle*) nullptr
std(, )java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
(* ::<JS>,&) nullptr,
}
TEST(ThenCatchWithCycleCollectedArgsJS, Empty)
{
nsCOMPtr(ThenCatchWithCycleCollectedArgsJSnsCOMPtrjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49
xpc:java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
xpcNativeGlobal(::PrivilegedJunkScope(); auto result = promise->ThenCatchWithCycleCollectedArgsJS(
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
eturn;
]JSContext,JSHandle:Value ErrorResult,Promise{
[](JSContext*, JS::Handle<JS return nullptr; return nullptr;
},
std::make_tuple(global), std::make_tuple());
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
(ThenCatchWithCycleCollectedArgsJS)
{
nsCOMPtr<nsIGlobalObject> global =
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for leng TEST, RefPtr
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
TEST(ThenCatchWithCycleCollectedArgsJS, RefPtrAndJSHandle
RefPtrPromisepromise ::(globalIgnoreErrors)java.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 68
nsCOMPtr<nsIGlobalObject> global[(*,JSHandleJS:>,ErrorResult*) java.lang.StringIndexOutOfBoundsException: Range [69, 70) out of bounds for length 69
(xpc:())java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
RefPtr
to =promise-(
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
:Handle::>) {return; }
[]
JS:Handle:Value return; }java.lang.StringIndexOutOfBoundsException: Index 52 out of bounds for length 52
std:(promise,stdmake_tuple::UndefinedHandleValue
}
TEST, )
{
AutoJSAPI ]JSContext*:Handle::> , & Promise
MOZ_ALWAYS_TRUE.Init::())java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
*cx .cx;
nsCOMPtr<nsIGlobalObject> global = xpc::CurrentNativeGlobal(cx);
TESTThenCatchWithCycleCollectedArgsJS )
RefPtr> =PromiseCreateglobal()) autoMOZ_ALWAYS_TRUEjsapi(xpc:PrivilegedJunkScope;
[](JSContext*, JS::HandleJSContextcx =.cxjava.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
::<JSObject(, (cx
>(
]JSContextJS:<::Value & nsIGlobalObjectjava.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 75
]JSContext ::Handle::>,ErrorResult,nsIGlobalObject
JS*, ::<JS:>,
std :<JSObject*>) { return nullptr; },
std:make_tupleJSUndefinedHandleValueJSHandleObject)));
} ::make_tuple(JS:UndefinedHandleValueJSHandleObject)))
Messung V0.5
array='360' stroke-dashoffset='0' /> H=100
¤ Dauer der Verarbeitung: 0.12 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.