| /arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/03.types/19.union_types/ |
| D | assignment_of_arrays_with_union_types.params.yaml | 9 # distributed under the License is distributed on an "AS IS" BASIS, 18 desc: Test an array with a union type of number and string. 22 desc: Test an array with a union type of boolean and number. 26 desc: Test an array with a union type of string and boolean. 30 desc: Test an array with a union type of number, string, and boolean. 34 desc: Test an array with a union type of an enum type and number. 44 desc: Test an array with a union type of an enum type and string. 54 desc: Test an array with a union type of an enum type and boolean. 64 desc: Test an array with a union type of an enum type, number, and string. 75 desc: Test an array with a union type of a string array and a boolean array. [all …]
|
| D | assignment_of_arrays_with_union_types_n.params.yaml | 9 # distributed under the License is distributed on an "AS IS" BASIS, 18 desc: Exception assignment of undefined to an array of object or string union type. 23 desc: Exception assignment of a number to an array of string or null union type. 27 desc: Exception assignment of a number to an array of boolean or object union type. 35 desc: Exception assignment of a date string to an array of custom class or number union type. 39 desc: Exception assignment of a boolean array to an array of string or function union type. 43 desc: Exception assignment of a string to an array of boolean or float type. 51 desc: Exception assignment of a date object to an array of custom class or Promise union type. 55 desc: Exception assignment of a string to an array of number or number[] type. 59 desc: Exception assignment of a number to an array of boolean or bigint union type. [all …]
|
| /arkcompiler/ets_frontend/ets2panda/test/runtime/ets/ |
| D | Multiline_string.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 17 let x = `This is an example of a multiline string, 20 type UT = `This is an example of a multiline string, 23 let x2:UT = `This is an example of a multiline string, 27 assertEQ(x2, `This is an example of a multiline string, 30 …assertEQ(x2, "This is an example of a multiline string,\n which should be enclo… 32 let x3 = `This is an example of a multiline string`; 33 type UT2 = `This is an example of a multiline string` | "X"; 34 let x4:UT2 = `This is an example of a multiline string` 36 assertEQ(x4, `This is an example of a multiline string`) [all …]
|
| D | nullableType.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 86 let an : A | null; 87 an = null; 88 an = new A(); 89 an = new A_alias(); 90 an = new NullableA_alias(); 91 an = new B(); 92 on = an; 100 na = an; 107 an = bn; [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_sdk/api/@ohos/util/ |
| D | LRUCacheExceptionTest.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 44 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") [all …]
|
| /arkcompiler/ets_frontend/ets2panda/test/ast/parser/ets/readonly-parameter-test/ |
| D | readonly-parameter-and-Readonly-test2.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 38 /* @@@ label6 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 39 /* @@@ label7 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 40 /* @@@ label8 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 41 /* @@@ label9 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 42 /* @@@ label Error TypeError: Cannot modify an array or tuple content that has the readonly paramet… 43 /* @@@ label1 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 44 /* @@@ label2 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 45 /* @@@ label3 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… 46 /* @@@ label4 Error TypeError: Cannot modify an array or tuple content that has the readonly parame… [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/stdlib/std/core/ |
| D | Json.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 53 * Error thrown when attempting to access a JSON element with an incompatible type. 91 * The class maintains an invariant that only one type of value can be set at a time. 188 * Gets a JSON element from an array by index. 191 * @throws {JsonTypeError} If this element is not an array 206 * Creates an undefined JSON element. 253 * Creates a new JSON element containing an integer value. 285 * Creates a new JSON element containing an undefined value. 294 * Creates a new JSON element containing an array of JSON elements. 305 * Creates a new JSON element containing an object with key-value pairs. [all …]
|
| D | Numeric.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 24 * Returns the value of an object as a byte 31 * Returns the value of an object as an int 38 * Returns the value of an object as a short 45 * Returns the value of an object as a long 52 * Returns the value of an object as a float 59 * Returns the value of an object as a double
|
| D | Errors.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 19 * @class Represents an error that occurs when assertion fails. 29 * @class Represents an error that occurs when division by zero is performed. 38 * @class Represents an error that occurs when null pointer is dereferenced. 47 * @class Represents an error that occurs when exception is thrown and not caught 56 * @class Represents an error that occurs when trying to interpret syntactically invalid code 69 * @class Represents an error that occurs when JSONValue can not be assigned to a type 78 * @class Represents an error that occurs when provided collection index is out of range 91 * @class Represents an error that occurs when array is oging to be indexed out of its bounds 109 * @class Represents an error that occurs when memory allocation fails [all …]
|
| /arkcompiler/ets_frontend/ets2panda/linter/arkanalyzer/src/core/graph/ |
| D | BaseImplicitGraph.ts | 10 * distributed under the License is distributed on an "AS IS" BASIS, 20 * BaseImplicitGraph is an abstract class that represents an implicit graph. 21 …* An implicit graph is a graph representation where node and edge information is implicitly stored… 26 * idToNodeMap is an optional map that maps node IDs (NodeID) to node objects (Node). 27 * If not initialized, calling related methods will throw an error. 39 * The key is a node ID (NodeID), and the value is an array of successor node IDs. 45 * The key is a node ID (NodeID), and the value is an array of predecessor node IDs. 60 * Returns an iterator for all nodes in the graph. 61 * @returns An iterator for traversing all nodes in the graph. 71 * @throws Throws an error if idToNodeMap is not initialized or if the node is not found. [all …]
|
| /arkcompiler/ets_frontend/ets2panda/linter/test/interop/ |
| D | reflect_built_in.ets.arkts2.json | 11 "distributed under the License is distributed on an 'AS IS' BASIS,", 24 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 34 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 44 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 54 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 64 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 74 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 114 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 124 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 134 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… [all …]
|
| D | reflect_built_in.ets.json | 11 "distributed under the License is distributed on an 'AS IS' BASIS,", 24 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 34 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 44 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 54 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 94 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 104 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 114 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 124 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… 134 …"rule": "Reflect API usage is not allowed in interop calls when an \"Object\" parameter receives a… [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/doc/annotations/ |
| D | annotations.rst | 8 distributed under the License is distributed on an "AS IS" BASIS, 16 An *annotation* is a special language element that changes the semantics of 19 The example below illustrates the declaring and using of an annotation: 36 An annotation must be placed immediately before the declaration it is applied to. 39 For an annotation to be used, its name must be prefixed with the symbol ``@`` 50 name is not accessible at the place of usage. An annotation declaration can be 72 The definition of a *user-defined annotation* is similar to that of an 90 As any other declarated entity, an annotation can be exported, using ``export`` keyword. 94 The default value of an *annotation field* can be specified 98 An *user-defined annotation* must be defined at top-level, [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/tests/ets_func_tests/regression/ |
| D | bigint_from_double.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 52 negativeTest("1.234e2", "not an integer"); 53 negativeTest("1e-7", "not an integer"); 54 negativeTest("0.0035", "not an integer"); 55 negativeTest("0.00023e4", "not an integer"); 56 negativeTest("+1e-1", "not an integer"); 57 negativeTest("-35.42", "not an integer"); 58 negativeTest("-3700e-3", "not an integer"); 59 negativeTest("-0.039", "not an integer"); 60 negativeTest("-0.0485e+3", "not an integer");
|
| /arkcompiler/runtime_core/static_core/plugins/ets/doc/spec/ |
| D | 18_annotations.rst | 8 distributed under the License is distributed on an "AS IS" BASIS, 24 The example below illustrates how an annotation is declared and used: 41 An annotation must be placed immediately before the declaration to which it is 42 applied. An annotation can include arguments as in the example above. 44 For an annotation to be used, the name of the annotation must be prefixed with 66 (see :ref:`Accessible`) at the place of usage. An annotation declaration can be 95 Declaring an *annotation* is similar to declaring an interface where the 112 As any other declared entity, an annotation can be exported by using the 117 The default value of an *annotation field* can be specified by using 138 The name of an *annotation* cannot coincide with the name of another entity: [all …]
|
| D | 10_interfaces.rst | 8 distributed under the License is distributed on an "AS IS" BASIS, 21 An interface declaration declares an *interface type*, i.e., a reference 42 Creating an instance of interface type is not possible. 44 An interface can be declared *direct extension* of one or more other 74 enough for a class to implement all methods of an interface. A class or one of 75 its superclasses must be actually declared to implement an interface. 124 The *identifier* in an interface declaration specifies the interface name. 126 An interface declaration with ``typeParameters`` introduces a new generic 129 The scope of an interface declaration is defined in :ref:`Scopes`. 152 An interface declared with an ``extends`` clause extends all other named [all …]
|
| /arkcompiler/runtime_core/static_core/tests/vm-benchmarks/src/vmb/plugins/tools/ |
| D | paoc.py | 12 # distributed under the License is distributed on an "AS IS" BASIS, 50 aot_stats = '--compiler-dump-stats-csv={an}.dump.csv ' 63 '--paoc-output={an}' 84 lib.with_suffix('.an'), 90 an = abc.with_suffix('.an') 93 res = self.run_paoc(abc, an, opts=opts) 97 an_size = self.x_sh.get_filesize(an) 100 bu.result.aot_stats = self.get_aot_stats(an, bu.path) 101 bu.binaries.append(an) 108 an: Union[str, Path], [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/07.expressions/01.evaluation_of_expressions/03.operator_precedence/ |
| D | null_coalescing.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 28 let an: A|null = null; 32 let res: boolean = ((an ?? a) instanceof I ? bn ?? b : an ?? a) === b 35 res = ((a ?? an) instanceof B ? an ?? a : bn ?? b) === b 42 let y: Object = an ?? b
|
| /arkcompiler/runtime_core/static_core/tests/checked/ |
| D | boot_an_location.pa | 9 # distributed under the License is distributed on an "AS IS" BASIS, 19 #! CHECKER boot aot with boot-an-location 20 …"--boot-panda-files=../test.abc --paoc-use-cha=false --paoc-output=./test.an --aot-verify-abs-pat… 22 #! RUN options: "--boot-panda-files=../test.abc --enable-an --boot-an-location=./ --aot-ve… 26 #! CHECKER boot aot without boot-an-location 27 #! RUN_PAOC options: "--boot-panda-files=../test.abc --paoc-output=./test.an --paoc-use-cha=fa… 29 #! RUN options: "--boot-panda-files=../test.abc --enable-an --aot-verify-abs-path=false", …
|
| D | force_an.pa | 9 # distributed under the License is distributed on an "AS IS" BASIS, 14 #! CHECKER Enable an 16 #! RUN options: "--enable-an", entry: "_GLOBAL::main" 19 #! CHECKER Enable an force 21 #! RUN options: "--enable-an:force", entry: "_GLOBAL::main", abort: 6
|
| /arkcompiler/ets_frontend/ets2panda/test/parser/ets/ |
| D | assignNullableToNonNullableTypeAlias.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 18 type AN = A | null; 22 let an : AN = new A(); 24 x = an;
|
| /arkcompiler/runtime_core/static_core/plugins/ets/stdlib/escompat/ |
| D | Errors.ets | 10 * distributed under the License is distributed on an "AS IS" BASIS, 19 * @class Represents an error that occurs when global eval() function fails 32 …* @class Represents an error that occurs when an operation could not be performed, typically (but … 45 …* @class Represents an error that occurs when a variable that doesn't exist (or hasn't yet been in… 58 …* @class Represents an error that occurs when a global URI handling function was used in a wrong w… 71 * The AggregateError object represents an error when several errors 81 * @param errors An iterable of errors, may not actually be Error 84 * @param s An human-readable description of the aggregate error. 87 * error. When catching and re-throwing an error with a
|
| /arkcompiler/ets_frontend/ets2panda/util/diagnostic/ |
| D | isolated_declgen.yaml | 9 # distributed under the License is distributed on an "AS IS" BASIS, 16 message: Variable must have an explicit type annotation when using isolated declaration. 20 message: Parameter must have an explicit type annotation when using isolated declaration. 24 message: Property must have an explicit type annotation when using isolated declaration. 44 message: Function must have an explicit return type annotation when using isolated declaration. 48 message: Method must have an explicit return type annotation when using isolated declaration.
|
| /arkcompiler/runtime_core/static_core/docs/ |
| D | aot_on_device.md | 14 …bc files in boot-panda-files. On device, some of these files maybe in boot an location, some of th… 16 …an` option to support try load AOT files from abc file location. To support load from /data/xxx, w… 18 The logic of loading an files for boot panda files will change to follows: 31 // If set boot-an-location, load from this location first 40 // If load failed from boot-an-location, continue try load from location of abc
|
| /arkcompiler/runtime_core/static_core/plugins/ets/doc/tutorial/ |
| D | functions.rst | 10 distributed under the License is distributed on an "AS IS" BASIS, 26 Below is an example of a simple function with two string parameters and string 37 the corresponding argument of an optional parameter can be omitted. The last 45 An optional parameter has the form '``name?: Type``': 57 Another form contains an expression that specifies a default value. If the 75 functions or methods can take an unlimited number of arguments: 124 If the name of a variable defined in the function is equal to the name of an 173 A function can be defined as an arrow function, for example: 181 If an arrow function return type is omitted, then it is inferred 184 An expression can be specified as an arrow function to make the notation [all …]
|