Home
last modified time | relevance | path

Searched full:throw (Results 1 – 25 of 1633) sorted by relevance

12345678910>>...66

/arkcompiler/ets_frontend/ets2panda/bindings/src/
DEs2pandaNativeModule.ts26 throw new Error('Not implemented');
38 throw new Error('Not implemented');
42 throw new Error('Not implemented');
45 throw new Error('Not implemented');
49 throw new Error('Not implemented');
53 throw new Error('Not implemented');
56 throw new Error('Not implemented');
60 throw new Error('Not implemented');
63 throw new Error('Not implemented');
66 throw new Error('Not implemented');
[all …]
/arkcompiler/ets_frontend/ets2panda/test/parser/js/
Dtest-throw-statement-expected.txt13 "program": "test-throw-statement.js"
18 "program": "test-throw-statement.js"
26 "program": "test-throw-statement.js"
31 "program": "test-throw-statement.js"
44 "program": "test-throw-statement.js"
49 "program": "test-throw-statement.js"
57 "program": "test-throw-statement.js"
62 "program": "test-throw-statement.js"
75 "program": "test-throw-statement.js"
80 "program": "test-throw-statement.js"
[all …]
Dtest-throw-statement.js17 throw 123
18 throw 123;
19 throw ''
20 throw '';
21 throw ""
22 throw "";
23 throw undefined
24 throw undefined;
25 throw null
26 throw null;
[all …]
/arkcompiler/ets_frontend/es2panda/test/parser/js/
Dtest-throw-statement.js17 throw 123
18 throw 123;
19 throw ''
20 throw '';
21 throw ""
22 throw "";
23 throw undefined
24 throw undefined;
25 throw null
26 throw null;
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/exceptions/sts_to_js/
Dexceptions.ets20 throw new Error("Throw Error from ets!");
25 throw new Error("Throw Error with cause from ets!", cause);
38 throw new CustomError("Throw Custom Error from ets!", 12345);
42 throw new Exception("Throw Exception from ets!");
51 throw new Exception("Throw Exception with cause from ets!", cause);
63 throw new CustomException("Throw Custom Exception from ets!", 54321);
/arkcompiler/ets_runtime/test/aottest/throw/
Dthrow.ts18 throw "Throw Test";
25 throw 123;
31 // throw an exception when superCall case1: supercallspread
41 throw new testError(message);
44 let thrown1 = new testError("throw from A1");
49 throw thrown1;
68 // throw an exception when superCall case2: supercallthisrange
69 let thrown2 = new testError("throw from A2");
73 throw thrown2;
93 //aot: when open inline mode, internal error should be throw correctly
[all …]
/arkcompiler/ets_frontend/ets2panda/test/ast/compiler/ets/
Dinitializer_block_namesapce03.sts18 /* @@ label1 */throw new Error();
20 try {/* @@ label2 */throw new Error()}
21 finally {/* @@ label3 */throw new Error()}
23 try {throw new Error()}
24 catch(e) {/* @@ label4 */throw new Error()}
28 /* @@@ label1 Error SyntaxError: Unhandled throw statement. */
29 /* @@@ label2 Error SyntaxError: Unhandled throw statement. */
30 /* @@@ label3 Error SyntaxError: Unhandled throw statement. */
31 /* @@@ label4 Error SyntaxError: Unhandled throw statement. */
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates_deprecated/02.multiple_catch_clauses_in_try_statements/
Dcatch2.ets51 throw new Ex("0");
54 throw new F("1", e);
57 throw new Ex("2", f);
60 throw new F("3", e);
63 throw new Ex("4", f);
66 throw new F("5", e);
69 throw new Ex("6", f);
72 throw new F("7", e);
75 throw new Ex("8", f);
78 throw new F("9", e);
[all …]
/arkcompiler/ets_frontend/ets2panda/linter/docs/rules/
Drecipe87.md1 # ``throw`` statements cannot accept values of arbitrary types
3 Rule ``arkts-limited-throw``
17 throw 4
18 throw ""
19 throw new Error()
28 throw new Error()
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_sdk/api/@ohos/util/
DLRUCacheExceptionTest.ets44 assertEQ(err.code, 401, "LRUCache should throw an exception when capacity is not int")
47 assertTrue(false, "LRUCache should throw an exception when capacity is not int");
55 assertEQ(err.code, 401, "LRUCache should throw an exception when capacity is not int")
58 assertTrue(false, "LRUCache should throw an exception when capacity is not int");
66 assertEQ(err.code, 401, "LRUCache should throw an exception when capacity is not int")
69 assertTrue(false, "LRUCache should throw an exception when capacity is not int");
77 assertEQ(err.code, 401, "LRUCache should throw an exception when capacity is negative")
80 assertTrue(false, "LRUCache should throw an exception when capacity is negative");
87 assertEQ(err.code, 401, "LRUCache should throw an exception when capacity is not int")
90 assertTrue(false, "LRUCache should throw an exception when capacity is not int");
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/error/js_to_ets/
Derror.js18 throw 0;
22 throw 'hello';
26 throw {a: 1, b: 2};
35 throw new SubError();
41 throw err;
45 throw new Error('null pointer error');
50 throw new Error('original error');
52 throw new Error('current error', { cause: originalError });
/arkcompiler/ets_frontend/ets2panda/linter/test/sdkwhite/
Dsdk_optional_methods.ets21 throw new Error('Method not implemented.');
25 throw new Error('Method not implemented.');
29 throw new Error('Method not implemented.');
33 throw new Error('Method not implemented.');
37 throw new Error('Method not implemented.');
41 throw new Error('Method not implemented.');
45 throw new Error('Method not implemented.');
49 throw new Error('Method not implemented.');
53 throw new Error('Method not implemented.');
57 throw new Error('Method not implemented.');
[all …]
/arkcompiler/ets_frontend/ets2panda/linter/test/main/
Dthrow_error.ets36 throw new A1();
37 throw new A11();
39 throw new A2();
40 throw new A22();
42 throw "Error";
43 throw "Error";
44 throw `Error${a}`;
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_func_tests/escompat/
DExceptionsTest.ets26 failures += test(testThrowException(), "Throw an Exception and catch it");
28 …failures += test(testThrowRuntimeException(), "Throw an RuntimeException object with message & cau…
29 failures += test(testThrowRuntimeExceptionWithoutArgs(), "Throw an RuntimeException object");
30 …failures += test(testThrowRuntimeExceptionWithoutReason(), "Throw an RuntimeException object with …
36 throw new Exception("Test throw");
48 throw new Exception("Test Exception with cause", cause);
60 throw new RuntimeException("Test RuntimeException", cause);
72 throw new RuntimeException();
84 throw new RuntimeException("Test RuntimeException");
DErrorCodeTest.ets28 throw new Error();
36 throw new Error(message);
44 throw new Error(message, new ErrorOptions(cause));
57 throw new Error(code);
65 throw new Error(code, message);
73 throw new Error(code, message, new ErrorOptions(cause));
85 throw new Error('name', undefined, undefined);
93 throw new Error('name', message, undefined);
101 throw new Error('name', undefined, new ErrorOptions(cause));
109 throw new Error('name', message, new ErrorOptions(cause));
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/08.statements/14.throw_statements/
Dthrow.params.yaml21 if (t1 != t2) throw p as Error;
34 if (t1 != t2) throw p as Error;
45 if (t1 != t2) throw new Err();
58 if (t1 != t2) throw new Err();
62 throw e;
80 throw f
86 if (t1 != t2) throw err;
88 throw p;
105 if (t1 != t2) throw p!;
118 if (t1 != t2) throw err
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_test_suite/coroutines/
Dlaunch_instruction.ets27 throw new Error();
39 throw new Error();
48 throw new Error();
52 throw new Error();
61 throw new Error();
65 throw new Error();
69 throw new Error();
78 throw new Error();
82 throw new Error();
86 throw new Error();
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/error/BuiltinError/ets_to_ts/
Dbuiltinerror.ets22 function GetThrowRangeError(): void {throw rangeErr;}
23 function GetThrowReferenceError(): void {throw referenceErr;}
24 function GetThrowSyntaxError(): void {throw syntaxErr;}
25 function GetThrowURIError(): void {throw uriErr;}
26 function GetThrowTypeError(): void {throw typeErr;}
71 throw new CustomRangeError(message);
74 throw new CustomReferenceError(message);
77 throw new CustomSyntaxError(message);
80 throw new CustomURIError(message);
83 throw new CustomTypeError(message);
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/test_esvalue2/
Desvalue_def_test.js23 export let jsFuncThrowNumber = function () { throw 5; };
24 export let jsFuncThrowString = function () { throw 'made error'; };
29 export let jsFuncWithParamThrowNumber = function (a, b) { throw 5; };
30 export let jsFuncWithParamThrowString = function (a, b) { throw 'made error'; };
47 throw 5;
50 throw 'made error';
58 throw 5;
61 throw 'made error';
74 throw 5;
80 throw 'made error';
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/09.classes/06.method_declarations/09.methods_returning_this/
Dmet_ret_this.params.yaml24 throw new Error
60 throw p as Error
75 throw p as Error
82 throw new Error
98 throw new Error
116 throw new Error
131 throw new Error
150 throw new Error
189 throw new Error
214 throw new Error
[all …]
Dmet_ret_this_n.params.yaml23 throw new Error
36 throw new Error
49 throw new Error
62 throw new Error
75 throw new Error
88 throw new Error
94 throw new Error
110 throw new Error
123 throw new Error
144 throw new Error
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/interop_js/tests/error/BuiltinError/ts_to_ets/
Dbuiltinerror.ts76 let rangeFunc1: () => void = () => { throw new RangeError(); };
77 let rangeFunc2: () => void = () => { throw new RangeError(SYNTAX_MESSAGE); };
78 let rangeFunc3: () => void = () => { throw new CustomRangeError(CUSTOM_SYNTAX_MESSAGE); };
84 let referenceFunc1: () => void = () => { throw new ReferenceError(); };
85 let referenceFunc2: () => void = () => { throw new ReferenceError(SYNTAX_MESSAGE); };
86 … let referenceFunc3: () => void = () => { throw new CustomReferenceError(CUSTOM_SYNTAX_MESSAGE); };
92 let syntaxFunc1: () => void = () => { throw new SyntaxError(); };
93 let syntaxFunc2: () => void = () => { throw new SyntaxError(SYNTAX_MESSAGE); };
94 let syntaxFunc3: () => void = () => { throw new CustomSyntaxError(CUSTOM_SYNTAX_MESSAGE); };
100 let uriFunc1: () => void = () => { throw new URIError(); };
[all …]
/arkcompiler/ets_frontend/es2panda/test/optimizer/js/unused-inst-opt/
Dunused-ldhole-expected.pa.txt28 throw.ifnotobject v8
60 throw
72 throw.ifnotobject v1
99 throw
144 throw
146 throw.ifnotobject v1
175 throw
178 throw
181 throw
/arkcompiler/runtime_core/static_core/tests/cts-generator/cts-template/
Dthrow.yaml23 - file-name: "throw"
25 title: Throw exception
26 description: Throw an exception located in register.
28 - sig: throw v:in:ref
38 - sig: throw v:in:ref
48 throw %s
57 - values: ['throw']
67 - sig: throw v:in:ref
78 throw %s
88 - sig: throw v:in:ref
[all …]
/arkcompiler/ets_frontend/es2panda/test/optimizer/ts/branch-elimination/projects/ts_ohmurl_project/
Dtest-import-exec-expected.pa.txt87 throw.undefinedifholewithname CONST_INT
89 throw.undefinedifholewithname CONST_DOUBLE
91 throw.undefinedifholewithname CONST_BOOL
93 throw.undefinedifholewithname CONST_BOOL
95 throw.undefinedifholewithname CONST_STRING
131 throw.undefinedifholewithname BUNDLE_FILE_TYPE
133 throw.undefinedifholewithname PACKAGE_FILE_TYPE
135 throw.undefinedifholewithname NORMALIZED_FILE_TYPE_1
137 throw.undefinedifholewithname NORMALIZED_FILE_TYPE_2
139 throw.undefinedifholewithname NORMALIZED_FILE_TYPE_3
[all …]

12345678910>>...66