Home
last modified time | relevance | path

Searched +full:2 +full:i (Results 1 – 25 of 1460) sorted by relevance

12345678910>>...59

/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/07.expressions/01.evaluation_of_expressions/03.operator_precedence/
Dunary.sts21 let i: int, b: boolean;
22 let t2 = 2, t3 = 3, t4 = 4, t8 = 8, t255 = 255, t258 = 258
25 i = + t2 * t4; if (i != 8) return 1;
26 i = + + t2 * t4; if (i != 8) return 1;
27 i = - t2 * t4; if (i != -8) return 1;
28 i = - - t2 * t4; if (i != 8) return 1;
29 i = ~ t2 * t4; if (i != -12) return 1;
30 i = ~ ~ t2 * t4; if (i != 8) return 1;
31 i = + - t2 * t4; if (i != -8) return 1;
32 i = + ~ t2 * t4; if (i != -12) return 1;
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/15.semantic_rules/07.overloading_and_overriding/04.overloading_and_overriding_in_classes/
Dinstance_method_over_n2.params.yaml17 …- { base: "i: Number|undefined|null", derived: "i: undefined|Number|null", call: "undefined", res:…
18 - { base: "i: Number|undefined|null", derived: "i: undefined|null|Number", call: "null", res: 2 }
20 …- { base: "i: Number, j: number", derived: "i: number, k: Number", call: "new Number(), 1", res: 1…
21 …- { base: "i: Number, j: number", derived: "i: number, k: Number", call: "1, new Number()", res: 2
25 - { base: "i: Number", derived: "i: Double", call: "new Number()", res: 2 }
26 - { base: "i: Number", derived: "i: Double", call: "new Double()", res: 2 }
27 - { base: "i: Double", derived: "i: Number", call: "new Number()", res: 2 }
28 - { base: "i: Double", derived: "i: Number", call: "new Double()", res: 2 }
30 - { base: "i: A", derived: "i: B", call: "new A()", res: 1 }
31 - { base: "i: A", derived: "i: B", call: "new B()", res: 2 }
[all …]
Dstatic_method_over_n2.params.yaml17 …- { base: "i: Number|undefined|null", derived: "i: undefined|Number|null", call: "undefined", res:…
18 - { base: "i: Number|undefined|null", derived: "i: undefined|null|Number", call: "null", res: 2 }
20 …- { base: "i: Number, j: number", derived: "i: number, k: Number", call: "new Number(), 1", res: 1…
21 …- { base: "i: Number, j: number", derived: "i: number, k: Number", call: "1, new Number()", res: 2
25 - { base: "i: Number", derived: "i: Double", call: "new Number()", res: 2 }
26 - { base: "i: Number", derived: "i: Double", call: "new Double()", res: 2 }
27 - { base: "i: Double", derived: "i: Number", call: "new Number()", res: 2 }
28 - { base: "i: Double", derived: "i: Number", call: "new Double()", res: 2 }
30 - { base: "i: A", derived: "i: B", call: "new A()", res: 1 }
31 - { base: "i: A", derived: "i: B", call: "new B()", res: 2 }
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/15.semantic_rules/07.overloading_and_overriding/02.override-compatible_signatures/
Doverride_variance.params.yaml19 foo(i: Derived): void {
23 override foo(i: Base): void {
24 res = 2;
27 result: 2
31 foo(i: Derived): void {
35 override foo(i: Base): void {
36 res = 2;
44 foo(i: Base): void {
48 override foo(i: Derived): void {
49 res = 2;
[all …]
Doverride_with_object.params.yaml19 foo(i: Base): void {
23 override foo(i: Object): void {
24 res = 2;
27 result: 2
31 foo(i: Base): void {
35 override foo(i: Object): void {
36 res = 2;
39 result: 2
44 foo(i: Object): void {
48 override foo(i: Base): void {
[all …]
Doverride_compatible_signature.params.yaml22 res = 2;
25 result: 2
36 res = 2;
39 result: 2
48 override foo(i: int): void {
49 res = 2;
52 result: 2
54 # different arguments number 2:1
57 foo(i: int, j: string): void {
61 override foo(i: int): void {
[all …]
/arkcompiler/ets_runtime/test/aottest/typedarrayfill/
Dtypedarrayfill.ts21 arr.fill(2, start, end);
23 for (let i = 0; i < start; i++) {
24 if (arr[i] == 2) {
28 for (let i = start; i < end; i++) {
29 if (arr[i] != 2) {
33 for (let i = end; i < length; i++) {
34 if (arr[i] == 2) {
50 arr.fill(2, start, end);
52 for (let i = 0; i < start; i++) {
53 if (arr[i] == 2) {
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/checked/
Didiom_memmove.sts33 let dst: int[] = [1, 2, 3, 4, 5];
39 for (let i:int = 0; i < src.length; i++) {
40 dst[i] = src[i];
53 let dst: int[] = [1, 2, 3, 4, 5];
55 for (let i:int = 0; i < src.length; i++) {
56 dst[i] = src[src.length - 1 - i];
69 let dst: int[] = [1, 2, 3, 4, 5];
71 for (let i:int = 0; i < src.length; i++) {
72 dst[dst.length - 1 - i] = src[i];
74 return check(dst, [1, 2, 8, 7, 6]);
[all …]
Dbounds_analysis_phi_in_loops.sts58 //! INST_COUNT "ZeroCheck", 2
64 //! INST_COUNT "ZeroCheck", 2
123 //! INST_COUNT "ZeroCheck", 2
129 //! INST_COUNT "ZeroCheck", 2
147 let arr : int[] = [0, 1, 2, 3, 4, 4, 3, 2, 1, 0];
149 for (let i = 0; i < arr.length; ++i) {
150 switch (arr[i]) {
157 case 2:
175 for (let i = 0; i < count; i++) {
177 if ((resources[i % i3 & (resourcesLength - 1)] & 1) == 0) {
[all …]
Dmemory_coalescing2.sts30 //! INST_COUNT /StoreObjectPair/, 2
52 //! INST_COUNT /StoreObjectPair/, 2
63 //! INST_COUNT /StoreObjectPair/, 2
85 //! INST_COUNT /StoreObjectPair/, 2
105 for (let j: int = 0; j < u.length; j = j + 2) {
109 for (let i: int = 0; i < v.length; i = i + 2) {
110 v[i] = t.i1;
111 v[i + 1] = t.i2 + 1;
119 for (let j: int = 0; j < u.length; j = j + 2) {
123 for (let i: int = 0; i < v.length; i = i + 2) {
[all …]
/arkcompiler/ets_runtime/ecmascript/base/
Djson_helper.cpp87 for (uint32_t i = 0; i < str.size(); ++i) { in AppendValueToQuotedString() local
88 const auto ch = static_cast<uint8_t>(str[i]); in AppendValueToQuotedString()
113 ++i; in AppendValueToQuotedString()
116 if (i + 2 < str.size() && // 2: Check 2 more characters in AppendValueToQuotedString()
117 …static_cast<uint8_t>(str[i + 1]) >= ALONE_SURROGATE_3B_SECOND_START && // 1: 1th character after ch in AppendValueToQuotedString()
118 … static_cast<uint8_t>(str[i + 1]) <= ALONE_SURROGATE_3B_SECOND_END && // 1: 1th character after ch in AppendValueToQuotedString()
119 … static_cast<uint8_t>(str[i + 2]) >= ALONE_SURROGATE_3B_THIRD_START && // 2: 2nd character after ch in AppendValueToQuotedString()
120 … static_cast<uint8_t>(str[i + 2]) <= ALONE_SURROGATE_3B_THIRD_END) { // 2: 2nd character after ch in AppendValueToQuotedString()
122 … reinterpret_cast<const uint8_t*>(str.c_str() + i), 3); // 3: Parse 3 characters in AppendValueToQuotedString()
125 i += 2; // 2 : Skip 2 characters in AppendValueToQuotedString()
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/03.types/08.reference_types/04.literal_types/
Doverriding_literal_types.params.yaml22 foo(i: string) {
27 foo(i: "some str") {
28 return 2
32 let i: Derived = new Derived()
33 assertEQ( i.foo("some str"), 2 )
41 foo(i: string) {
46 foo(i: "some str") {
47 return 2
51 let i: Derived = new Derived()
52 assertEQ( i.foo(new String("some str")), 2 )
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/15.semantic_rules/07.overloading_and_overriding/05.overloading_and_overriding_in_interfaces/
Dmultiple_interfaces_inheritance.params.yaml17 interface I {
18 foo(i: number) {
22 interface J extends I {
24 return 2;
27 class A implements I, J {}
31 assert(a.foo("some string") == 2);
34 interface I {
35 foo(i: number) {
39 interface J extends I {
41 return 2;
[all …]
Dim_over.params.yaml18 interface I {
26 type J = I
28 interface I {
29 meth(p: I)
37 interface I {
58 interface I extends J {
69 class A implements I {
73 meth(p: short): int { return 2 }
89 let i: I = new A()
90 assert(i.meth(new Byte(-1 as byte)) == 11)
[all …]
/arkcompiler/ets_runtime/test/moduletest/container/
Dcontainer_vector.js36 vector.insert(2, 2);
38 map.set("test get(index is 2):", vector.get(2) == 2);
41 map.set("test getIndexOf(target is 2):", vector.getIndexOf(2) !== 5); // false
50 vec.set(2, 8);
51 map.set("test set:", vec.get(2) == 8 && vec.length == 6);
62 return (item = 2 * item);
70 for (let i = 0; i < vector.length; i++) {
71 map.set("for of " + arr[i], vec.get(i) == arr[i]);
87 for(let i = 0; i<10; i++) {
88 proxy.add(i)
[all …]
/arkcompiler/ets_runtime/test/moduletest/loadicbyname/
Dloadicbyname.js26 for (let i = 0; i < 100; i++) {
37 for (let i = 0; i < 50; i++)
45 for (let i = 0; i < 50; i++)
58 for (let i = 0; i < 50; i++)
67 for(let i=0;i<2;i++){
77 for (let i = 0; i < 100; i++) {
87 for (let i = 0; i < 100; i++) {
90 for (let i = 0; i < 100; i++) {
110 for (let i = 0; i < 100; i++) { };
150 for(let i=0;i<2;i++){
[all …]
/arkcompiler/ets_frontend/ets2panda/test/runtime/ets/
Dassignment_lowering.sts31 let x: int[] = [1, 2, 3];
33 for (let i: int = 0; i < 3; ++i) {
34 i <<= 2;
36 x[i >> 2] *= 2;
37 i >>= 2;
40 for (let i: int = 0; i < 3; ++i) {
41 assert (x[i] == (i + 1) * 2);
/arkcompiler/ets_frontend/ets2panda/linter/test/main/
Dfor_stmts.sts27 * OK, spec 7.5.2 Type inference from Types of Elements
49 for (const i in list) {
50 if (true) console.log(i); // "0", "1", "2",
53 for (const i of list) {
54 console.log(i); // 4, 5, 6
57 for (const i of [4, 5, 6]) {
58 console.log(i); // 4, 5, 6
75 for (const i in s) {
76 if (true) console.log(i);
85 let i: number, j: number, k: number;
[all …]
/arkcompiler/ets_runtime/test/moduletest/arraySome/
DarraySome.js19 const result = [1, 2, 3].some((x, i, arr) => {
20 log.push({ value: x, index: i, array: [...arr] });
21 return x > 2;
28 const result = [1, 2, 3].some((x, i, arr) => {
29 log.push({ value: x, index: i, array: [...arr] });
37 const result = [].some((x, i, arr) => {
38 log.push({ value: x, index: i, array: [...arr] });
46 const result = [false, 0, ''].some((x, i, arr) => {
47 log.push({ value: x, index: i, array: [...arr] });
55 const result = [1, 2, 3].some((x, i, arr) => {
[all …]
/arkcompiler/runtime_core/static_core/plugins/ets/tests/ets-templates/04.names_declarations_and_scopes/08.function_declarations/03.readonly_parameters/
Dreadonly_context_and_conversion.params.yaml19 foo(i: readonly int[]) {
22 foo(i: int[]) {
23 return 2;
27 let ro: readonly int[] = [1, 2];
34 foo(i: int[]) {
35 return 2;
39 let ro: readonly int[] = [1, 2];
45 foo(i: Array<int>) {
48 foo(i: readonly Array<int>) {
49 return 2;
[all …]
/arkcompiler/ets_runtime/test/aottest/array_bounds_check_elimination/
Darray_bounds_check_elimination.ts31 for (let i = 0; i < x; i++) {
32 a[i] = 0;
37 for (let i = 0; i < x; i++) {
38 b[i] = 0;
42 function triple(a: number[], i: number) {
43 a[i + 3] = 0;
44 a[i + 1] = 0;
45 a[i + 2] = 0;
51 a[2] = 0;
54 let a: number[] = [1, 2, 3];
[all …]
/arkcompiler/ets_runtime/test/moduletest/arrayfindindex/
Darrayfindindex.js59 const result = [1, 2, 3, 4].findIndex((x, i, arr) => {
60 log.push({ value: x, index: i, array: [...arr] });
63 print("Log:", JSON.stringify(log), "Result:", JSON.stringify(result)); // Result: 2
68 const result = [1, 2, 3, 4].findIndex((x, i, arr) => {
69 log.push({ value: x, index: i, array: [...arr] });
77 const result = [].findIndex((x, i, arr) => {
78 log.push({ value: x, index: i, array: [...arr] });
86 const result = [false, 0, ''].findIndex((x, i, arr) => {
87 log.push({ value: x, index: i, array: [...arr] });
95 const result = [1, 2, 3, 4].findIndex((x, i, arr) => {
[all …]
/arkcompiler/toolchain/tooling/test/testcases/js/
Ddropframe.js18 a = 2;
26 d = 2;
43 d = d * 2;
55 a = a * 2;
67 a = a * 2;
72 for (let i = 1; i <= 2; i++) {
81 for (let i = 1; i <= 2; i++) {
83 d = d + i * j;
85 a = a * i;
88 d = d * i * j + c;
[all …]
/arkcompiler/runtime_core/compiler/tests/
Dreg_alloc_interference_graph_new_test.cpp48 auto IsInSet(unsigned expect_edges[][2], size_t count, unsigned a, unsigned b) in IsInSet() argument
51 for (size_t i = 0; i < count; i++) { in IsInSet() local
52 if ((a == expect_edges[i][0] && b == expect_edges[i][1]) || in IsInSet()
53 (b == expect_edges[i][0] && a == expect_edges[i][1])) { in IsInSet()
69 for (unsigned i = 0; i < count; i++) { in BuildSubgraph() local
70 auto x = edges[i].first; in BuildSubgraph()
71 auto y = edges[i].second; in BuildSubgraph()
96 unsigned test_edges[2][2] = {{0, 1}, {7, 4}};
99 for (unsigned i = 0; i < 10; i++) { variable
101 EXPECT_EQ(matrix.HasEdge(i, j), IsInSet(test_edges, 2, i, j));
[all …]
/arkcompiler/ets_runtime/test/jittest/deopt/
Ddeopt.ts18 for (let j = 0; j < 2; j++) {
22 for (let i = 0; i < 2; i++) {
29 for (let i = 0; i < 2; i++) {
38 for (let i = 0; i < 2; i++) {
47 let i = 0;
51 i = i + array[j];
54 return i;
58 for (let i = 0; i < 2; i++) { variable
59 array.push(i);

12345678910>>...59