Home
last modified time | relevance | path

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

12345678910>>...28

/arkcompiler/ets_runtime/test/typeinfer/automatedcases/
DtaggedTemplateStringsWithTypedTags.ts21 interface I {
22 (stringParts: TemplateStringsArray, ...rest: number[]): I;
23 g: I;
24 h: I;
25 member: I;
27 [x: number]: I;
30 let f: I;
31 AssertType(f, "I");
34 AssertType(f `abc`, "I");
35 AssertType(f, "I");
[all …]
DtaggedTemplateStringsWithTypedTagsES6.ts21 interface I {
22 (stringParts: TemplateStringsArray, ...rest: number[]): I;
23 g: I;
24 h: I;
25 member: I;
27 [x: number]: I;
30 let f: I;
31 AssertType(f, "I");
34 AssertType(f `abc`, "I");
35 AssertType(f, "I");
[all …]
DnumericIndexingResults.ts24 "2" = ''
36 let r2 = c['2'];
38 AssertType(c['2'], "string");
40 AssertType('2', "string");
54 let r5 = c[2];
56 AssertType(c[2], "string");
58 AssertType(2, "int");
66 interface I { interface
69 "2": string;
72 let i: I variable
[all …]
DcallSignaturesWithOptionalParameters2.ts44 foo2(1, 2);
45 AssertType(foo2(1, 2), "any");
48 AssertType(2, "int");
76 c.foo2(1, 2);
77 AssertType(c.foo2(1, 2), "any");
80 AssertType(2, "int");
82 interface I { interface
89 let i: I; variable
90 AssertType(i, "I");
92 i();
[all …]
DcommaOperatorInConditionalExpression.ts22 [1, 2, 3].map(i => {
23 AssertType([1, 2, 3].map, "<U>((number, number, number[]) => U, ?any) => U[]");
24 AssertType([1, 2, 3], "number[]");
26 AssertType(2, "int");
28 AssertType(i => { return true? { [m]: i } : { [m]: i + 1 } }, "(number) => { [string]: nu…
29 AssertType(i, "number");
30 AssertType([1, 2, 3].map(i => { return true? { [m]: i } : { [m]: i + 1 } }), "{ [string]:…
32 AssertType(true? { [m]: i } : { [m]: i + 1 }, "{ [string]: number; }");
33 return true? { [m]: i } : { [m]: i + 1
37 AssertType({ [m]: i }, "{ [string]: number; }");
[all …]
DES5For-of37.ts23 for (const i of [0, 1, 2, 3, 4]) {
26 for (const j of [1, 2, 3]) {
28 AssertType([1, 2, 3], "number[]");
30 AssertType(2, "int");
33 if (i === 2) {
34 AssertType(i === 2, "boolean");
35 AssertType(i, "number");
36 AssertType(2, "int");
44 console.log(i);
45 AssertType(console.log(i), "void");
[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 …]
Dcontainer_plainarray.js29 let testArray = ["0", "1", "2", "3", "4", "5"]
33 proxy.add(2, "2")
38 for(let i = 0; i < testArray.length; i++) {
39 if (proxy[i] !== testArray[i]) {
45 map.set("test plainarray has:", proxy.has(2))
49 map.set("test plainarray getValueAt:", proxy.getValueAt(2) === "2")
53 for(let i = 0; i < testArray.length; i++) {
54 if (newPlainArray[i] !== testArray[i]) {
64 proxy.removeAt(2)
65 testArray.splice(2, 1)
[all …]
/arkcompiler/ets_runtime/test/moduletest/array/
Darray.js27 arr1.fill(0, 2, 4);
31 arr2.fill(0, 2, 4);
36 var arr3 = [1,2,3,4,5,6];
42 arr4.splice(1, 0, 2);
45 // 1, 2, 3, 4
46 var arr4 = [1,2,3,4];
50 // 1, 2, 3, 3
52 var arr5 = [1,2,3,4,5,6];
56 // 1, 2, 3, 4, 5
58 var arr6 = [1,2,3,4,5];
[all …]
/arkcompiler/runtime_core/compiler/tests/
Dreg_alloc_interference_graph_test.cpp27 unsigned test_edges1[2][2] = {{0, 1}, {7, 4}};
29 for (int i = 0; i < 2; i++) { in __anon5bb9e09a0202() local
30 …if ((a == test_edges1[i][0] && b == test_edges1[i][1]) || (b == test_edges1[i][0] && a == test_edg… in __anon5bb9e09a0202()
44 for (unsigned i = 0; i < DEFAULT_CAPACITY1; i++) { in TEST_F() local
46 ASSERT_EQ(matrix.HasEdge(i, j), IsInSet(i, j)); in TEST_F()
58 for (unsigned i = 0; i < DEFAULT_CAPACITY1; i++) { in TEST_F() local
60 EXPECT_EQ(matrix.HasAffinityEdge(i, j), IsInSet(i, j)); in TEST_F()
77 EXPECT_EQ(gr.Size(), 2); in TEST_F()
101 gr.AddEdge(1, 2); in TEST_F()
104 gr.AddEdge(0, 2); in TEST_F()
[all …]
Dinst_test.cpp33 * [2] in TEST_F()
46 * PHI(1,2,4) in TEST_F()
54 BASIC_BLOCK(2, 3, 4) in TEST_F()
56 INST(2, Opcode::Add).u64().Inputs(0, 1); in TEST_F()
72 INST(7, Opcode::Sub).u64().Inputs(3, 2); in TEST_F()
87 ASSERT_TRUE(CheckUsers(INS(0), {2, 3, 8, 11})); in TEST_F()
88 ASSERT_TRUE(CheckUsers(INS(1), {2, 4, 8, 11})); in TEST_F()
89 ASSERT_TRUE(CheckUsers(INS(2), {7})); in TEST_F()
93 ASSERT_TRUE(CheckInputs(INS(2), {0, 1})); in TEST_F()
95 ASSERT_TRUE(CheckInputs(INS(7), {3, 2})); in TEST_F()
[all …]
Dgraph_cloner_test.cpp38 CONSTANT(2, 10); // len_array in TEST_F()
40 BASIC_BLOCK(2, 3, 6) in TEST_F()
43 INST(3, Opcode::NewArray).ref().Inputs(44, 2); in TEST_F()
44 INST(14, Opcode::Compare).CC(ConditionCode::CC_LT).b().Inputs(0, 13); // i < X in TEST_F()
50 INST(7, Opcode::SaveState).Inputs(0, 1, 2, 3).SrcVregs({0, 1, 2, 3}); in TEST_F()
51 INST(8, Opcode::BoundsCheck).s32().Inputs(2, 4, 7); in TEST_F()
52 INST(9, Opcode::StoreArray).s32().Inputs(3, 8, 0); // a[i] = 0 in TEST_F()
53 INST(10, Opcode::Add).s32().Inputs(4, 1); // i++ in TEST_F()
54 INST(5, Opcode::Compare).CC(ConditionCode::CC_LT).b().Inputs(10, 13); // i < X in TEST_F()
70 CONSTANT(2, 10); // len_array in TEST_F()
[all …]
/arkcompiler/ets_runtime/test/moduletest/typearray/
Dtypearray.js32 ].forEach(function(ctor, i) { argument
45 ].forEach(function(ctor, i) { argument
65 for (let i = 0; i < result.length; i++) {
66 if (!result[i]) {
76 for (let i = 0; i < 5; i++) {
77 obj[i] = i;
80 for (let i = 0; i < 5; i++) {
81 result.push(child[i] == undefined);
83 for (let i = 0; i < result.length; i++) {
84 if (!result[i]) {
[all …]
/arkcompiler/ets_frontend/ts2panda/templates/
DbuiltinsMap.ts.erb72 % for i in 2..args_len-1 # ignore first two opcode
73 % if (args[i].start_with?("imm"))
74 if (!(operands[<%= i-2%>] instanceof ir.Imm)) {
75 throw new Error("<%= i-2%> parameters must be Imm <" + ins.toString() + ">");
76 % parameters += ", <ir.Imm>operands[" + (i-2).to_s + "]"
78 % elsif (args[i].start_with?("v"))
79 if (!(operands[<%= i-2%>] instanceof ir.VReg)) {
80 throw new Error("<%= i-2%> parameters must be VReg <" + ins.toString() + ">");
81 % parameters += ", <ir.VReg>operands[" + (i-2).to_s + "]"
83 % elsif (args[i].include?("string_id"))
[all …]
/arkcompiler/ets_runtime/test/aottest/range_guard/
Drange_guard.ts18 let testArray: Int32Array = new Int32Array([1, 2, 3]);
26 let testArray: Int32Array = new Int32Array([1, 2, 3]);
34 let testArray: Int32Array = new Int32Array([1, 2, 3]);
37 for(let i = 0; i < len; i++) {
38 print(i + 1);
39 sum += testArray[i];
44 let testArray: Int32Array = new Int32Array([1, 2, 3]);
47 for(let i = 0; i < len; i++) {
48 sum += testArray[i];
49 print(i + 1);
[all …]
/arkcompiler/runtime_core/libpandabase/tests/
Dbit_table_test.cpp53 for (size_t i = 0; i < N; i++) { in CreateEntry() local
54 entry[i] = data[i]; in CreateEntry()
121 ASSERT_EQ(table.GetRow(2).Get(0), 19); in TEST_F()
131 {{0U, 1U, 2U, 3U, 4U, 5U, 6U, 7U, 8U, 9U}, in TEST_F()
133 … {0_KB, 1_KB + 1, 1_KB + 2, 1_KB + 3, 1_KB + 4, 1_KB + 5, 1_KB + 6, 1_KB + 7, 1_KB + 8, 1_KB + 9}, in TEST_F()
134 … {0_MB, 0_MB + 1, 1_MB + 2, 1_MB + 3, 1_MB + 4, 1_MB + 5, 1_MB + 6, 1_MB + 7, 1_MB + 8, 1_MB + 9}, in TEST_F()
135 …{0_GB, 0_GB + 1, 0_GB + 2, 1_GB + 3, 1_GB + 4, 1_GB + 5, 1_GB + 6, 1_GB + 7, 1_GB + 8, 1_GB + 9}}}; in TEST_F()
140 builder.Emplace(CreateEntry<decltype(builder)>(values[2])); in TEST_F()
155 for (size_t i = 0; i < row.ColumnsCount(); i++) { in TEST_F() local
156 ASSERT_EQ(row.Get(i), values[row_index][i]); in TEST_F()
[all …]
Dregmask_test.cpp34 for (size_t i = 0; i < base.size(); i++) { in CompareWithBitset() local
35 ASSERT_EQ(mask.Test(i), base.test(i)); in CompareWithBitset()
36 ASSERT_EQ(mask[i], base[i]); in CompareWithBitset()
45 for (size_t i = 0; i < base.size(); i++) { in TestRegMask() local
46 mask.set(i); in TestRegMask()
47 base.set(i); in TestRegMask()
49 mask.reset(i); in TestRegMask()
50 base.reset(i); in TestRegMask()
69 TestRegMask(MakeMask(0, 3, 2, 17, 25, 31));
78 RegMask mask(MakeMask(0, 2, 3, 17, 25, 31));
[all …]
Dmath_helpers_test.cpp26 for (uint32_t i = 1; i < 32; i++) { variable
27 val = 1U << i;
28 EXPECT_EQ(GetIntLog2(val), i);
32 for (int i = 1; i < 32; i++) { variable
33 val = (1U << i) + (i == 31 ? -1 : 1);
43 EXPECT_TRUE(IsPowerOfTwo(2));
56 for (int i = 0; i <= 1; i++) { variable
57 EXPECT_EQ(GetPowerOfTwoValue32(i), 1U);
59 for (int i = 2; i <= 2; i++) { variable
60 EXPECT_EQ(GetPowerOfTwoValue32(i), 2U);
[all …]
/arkcompiler/ets_frontend/es2panda/util/
Dbase64.cpp28 …for (size_t i = 0, j = 0; i < encodedRes.length() - 2; i += TRANSFORMED_CHAR_NUM, j += TO_TRANSFOR… in Base64Encode() local
31 encodedRes[i] = base64CharSet[(inputString[j] & 0xff) >> 2]; in Base64Encode()
32 // 00 + the last 2 bits of the first char + the first 4 bits of the second char in Base64Encode()
33 …encodedRes[i + 1] = base64CharSet[(inputString[j] & 0x03) << 4 | (inputString[j + 1] & 0xf0) >> 4]; in Base64Encode()
34 // 00 + last 4 bits of the second char + the first 2 bits of the third char in Base64Encode()
35 …encodedRes[i + 2] = base64CharSet[(inputString[j + 1] & 0x0f) << 2 | (inputString[j + 2] & 0xc0) >… in Base64Encode()
37 encodedRes[i + 3] = base64CharSet[inputString[j + 2] & 0x3f]; in Base64Encode()
41 encodedRes[encodedRes.length() - 2] = '='; in Base64Encode()
44 case 2: in Base64Encode()
65 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, in Base64Decode()
[all …]
/arkcompiler/ets_runtime/tools/circuit_viewer/src/engine/graphics/
DXMat4.js34 for (let i = 0; i < 4; i++) {
36 this.mat[i][j] = m.mat[i][j];
45 this.mat[1][2] = -_sin;
46 this.mat[2][1] = _sin;
47 this.mat[2][2] = _cos;
54 this.mat[0][2] = -_sin;
55 this.mat[2][0] = _sin;
56 this.mat[2][2] = _cos;
72 this.mat[2][2] = z;
77 this.mat[3][2] += z;
[all …]
/arkcompiler/runtime_core/tests/cts-assembly/
Darrays-06.pa41 # for (int i = 0; i < n; i++) {
42 # arr[i] = 4;
43 # sum += arr[i];
51 # for (int i = 0; i < n; i++) {
52 # arr[i] = 3;
53 # sum += arr[i];
55 # n += 2;
63 # for (int i = 0; i < n; i++) {
64 # arr[i] = 2;
65 # sum += arr[i];
[all …]
/arkcompiler/ets_runtime/ecmascript/tests/
Dtagged_tree_test.cpp226 EXPECT_EQ(tmap->NumberOfElements(), 2); in HWTEST_F_L0()
259 EXPECT_EQ(tset->NumberOfElements(), 2); in HWTEST_F_L0()
279 for (int i = 0; i < NODE_NUMBERS; i++) { in HWTEST_F_L0() local
280 keyArray[5] = '1' + static_cast<uint32_t>(i); // 5 means index of keyArray in HWTEST_F_L0()
283 JSHandle<JSTaggedValue> value(thread, JSTaggedValue(i)); in HWTEST_F_L0()
289 for (int i = 0; i < NODE_NUMBERS; i++) { in HWTEST_F_L0() local
290 keyArray[5] = '1' + static_cast<uint32_t>(i); // 5 means index of keyArray in HWTEST_F_L0()
295 EXPECT_EQ(JSTaggedValue(i), res); in HWTEST_F_L0()
308 for (int i = 0; i < NODE_NUMBERS; i++) { in HWTEST_F_L0() local
309 keyArray[5] = '1' + static_cast<uint32_t>(i); // 5 means index of keyArray in HWTEST_F_L0()
[all …]
/arkcompiler/ets_frontend/ts2panda/tests/expression/
DprefixOperations.test.ts46 it('let i = 5; ++i', function () {
47 let insns = compileMainSnippet("let i = 5; let j = ++i");
48 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = ++i"), 0, undefined);
54 new Sttoglobalrecord(new Imm(0), 'i'),
55 new Tryldglobalbyname(new Imm(1), 'i'),
58 new Inc(new Imm(2)),
59 new Trystglobalbyname(new Imm(3), 'i'),
67 it('let i = 5; --i', function () {
68 let insns = compileMainSnippet("let i = 5; let j = --i");
69 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = --i"), 0, undefined);
[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/ets_runtime/test/aottest/pgo_call/
Dpgo_call.ts23 return a / 2;
42 for (let i = 0; i < 2; i++) { variable
43 callFoo1(foo, i);
46 for (let i = 0; i < 2; i++) { variable
47 callFoo2(foo, i);
50 for (let i = 0; i < 2; i++) { variable
51 callFoo2(bar, i);

12345678910>>...28