/arkcompiler/ets_frontend/ts2panda/src/expression/ |
D | arrayLiteralExpression.ts | 47 let element = elements[i]; 49 if (isConstantExpr(element)) { 50 let elem = parseConstantExpr(element); 55 emitCreateArrayWithBuffer(pandaGen, literalBuffer, element); 56 pandaGen.storeAccumulator(element, arrayObj); 62 compiler.compileExpression(element); 64 storeElementIfSpreadExisted(pandaGen, element, arrayObj, indexReg); 66 pandaGen.storeOwnProperty(element, arrayObj, i); 71 if (ts.isSpreadElement(element)) { 73 emitCreateArrayWithBuffer(pandaGen, literalBuffer, element); [all …]
|
/arkcompiler/ets_frontend/es2panda/compiler/base/ |
D | destructuring.cpp | 43 // create left reference for rest element in GenRestElement() 83 for (const auto *element : array->Elements()) { in GenArray() local 86 if (element->IsRestElement()) { in GenArray() 87 GenRestElement(pg, element->AsRestElement(), iterator, array->IsDeclaration()); in GenArray() 92 if (element->IsOmittedExpression()) { in GenArray() 98 const ir::Expression *target = element; in GenArray() 100 if (element->IsAssignmentPattern() || element->IsAssignmentExpression()) { in GenArray() 101 auto *assignment = element->IsAssignmentPattern() ? element->AsAssignmentPattern() : in GenArray() 102 element->AsAssignmentExpression(); in GenArray() 113 pg->BranchIfStrictUndefined(element, defaultInit); in GenArray() [all …]
|
D | literals.cpp | 45 for (const auto *element : templateLit->Quasis()) { in GetTemplateObject() local 46 pg->LoadAccumulatorInt(element, elemIndex); in GetTemplateObject() 47 pg->StoreAccumulator(element, indexReg); in GetTemplateObject() 49 pg->LoadAccumulatorString(element, element->Raw()); in GetTemplateObject() 50 pg->StoreObjByValue(element, rawArr, indexReg); in GetTemplateObject() 52 pg->LoadAccumulatorString(element, element->Cooked()); in GetTemplateObject() 53 pg->StoreObjByValue(element, cookedArr, indexReg); in GetTemplateObject()
|
/arkcompiler/ets_runtime/test/moduletest/arrayfindlast/ |
D | arrayfindlast.js | 25 result = arr.findLast((element, index, array) => { 27 return (element == 5); 30 result = arr.findLast((element) => { 31 return element > 2; 35 result = arr.findLastIndex((element, index, array) => { 39 return (element == 100); 42 result = arr.findLastIndex((element, index, array) => { 43 return (element == 100); 48 result = arr2.findLast((element, index, array) => { 49 return (element == undefined); [all …]
|
/arkcompiler/ets_frontend/ts2panda/src/ |
D | compilerUtils.ts | 92 let element = arr.elements[i]; 96 if (ts.isOmittedExpression(element)) { 101 // if its spread element 102 if ((!isDeclaration && ts.isSpreadElement(element)) || 103 (isDeclaration && (<ts.BindingElement>element).dotDotDotToken)) { 104 …emitRestElement(isDeclaration ? (<ts.BindingElement>element).name : (<ts.SpreadElement>element).ex… 106 pandaGen.branch(element, endLabel); 111 … let target: ts.Node = isDeclaration ? (<ts.BindingElement>element).name : <ts.Expression>element; 114 if (!isDeclaration && ts.isBinaryExpression(element)) { 115 if (element.operatorToken.kind != ts.SyntaxKind.EqualsToken) { [all …]
|
D | recorder.ts | 416 namedBindings.elements.forEach((element) => { 417 let name: string = jshelpers.getTextOfIdentifierOrLiteral(element.name); 418 …let exoticName: string = element.propertyName ? jshelpers.getTextOfIdentifierOrLiteral(element.pro… 420 … importStmt.addNodeMap(element.name, element.propertyName ? element.propertyName : element.name); 451 namedBindings.elements.forEach((element) => { 452 let name: string = jshelpers.getTextOfIdentifierOrLiteral(element.name); 453 …let exoticName: string = element.propertyName ? jshelpers.getTextOfIdentifierOrLiteral(element.pro… 455 … exportStmt.addNodeMap(element.name, element.propertyName ? element.propertyName : element.name); 482 namedBindings.elements.forEach((element: any) => { 483 let localName: string = jshelpers.getTextOfIdentifierOrLiteral(element.name); [all …]
|
/arkcompiler/ets_runtime/test/moduletest/typedarrayfindlast/ |
D | typedarrayfindlast.js | 55 let result1 = obj.findLast((element, index, array) => { 56 return (element == 12); 59 result1 = obj.findLast((element, index, array) => { 60 return (element < 10); 63 result1 = obj.findLastIndex((element, index, array) => { 67 return (element == 100); 70 result1 = obj.findLastIndex((element, index, array) => { 71 return (element == 100); 85 let result1 = obj.findLast((element, index, array) => { 86 return (element == 12n); [all …]
|
/arkcompiler/runtime_core/libpandabase/utils/ |
D | ring_buffer.h | 145 * Appends the given element value to the end of the ring buffer 146 * @param value the value of the element to append 155 * Moves the given element value to the end of the ring buffer 156 * @param value the value of the element to append 164 * Appends a new element to the end of the ring buffer 167 * @param args arguments to forward to the constructor of the element 168 * @return a reference to the inserted element 179 * Appends the given element value to the begin of the ring buffer 180 * @param value the value of the element to append 189 * Moves the given element value to the begin of the ring buffer [all …]
|
/arkcompiler/ets_runtime/test/typeinfer/automatedcases/ |
D | commentOnArrayElement1.ts | 23 AssertType([ /* element 1*/ 1 /* end of element 1 */, 2 /* end of element 2 */], "nu… 25 /* element 1*/ 29 /* end of element 1 */, 33 /* end of element 2 */
|
D | commentOnArrayElement3.ts | 23 AssertType([ /* element 1*/ 1 /* end of element 1 */, 2 /* end of element 2 */, , … 25 /* element 1*/ 29 /* end of element 1 */, 33 /* end of element 2 */, ,
|
D | commentOnArrayElement2.ts | 23 AssertType([ /* element 1*/ 1 /* end of element 1 */, 2 /* end of element 2 */], "numbe… 25 /* element 1*/ 26 1 /* end of element 1 */, 32 /* end of element 2 */
|
D | varArgsOnConstructorTypes.ts | 29 constructor(element: any, url: string) { 30 super(element); 31 AssertType(super(element), "void"); 33 AssertType(element, "any"); 35 this.p1 = element; 36 AssertType(this.p1 = element, "any"); 39 AssertType(element, "any");
|
D | assignmentGenericLookupTypeNarrowing.ts | 36 const element = foo(mappedObject[key]); constant 37 AssertType(element, "{ foo: { x: string; }; }[K]"); 44 if (element == null) 45 AssertType(element == null, "boolean"); 46 AssertType(element, "{ foo: { x: string; }; }[K]"); 50 const x = element.x; 52 AssertType(element.x, "string");
|
D | genericSpecializationToTypeLiteral1.ts | 38 …sequenceEqual<TCompare>(second: IEnumerable<T>, compareSelector: (element: T) => TCompare): boolea… 40 sequenceEqual<TCompare>(second: T[], compareSelector: (element: T) => TCompare): boolean; 42 toDictionary<TKey>(keySelector: (element: T) => TKey): IDictionary<TKey, any>; 43 …toDictionary<TKey, TValue>(keySelector: (element: T) => TKey, elementSelector: (element: T) => TVa… 44 …toDictionary<TKey, TValue, TCompare>(keySelector: (element: T) => TKey, elementSelector: (element:…
|
D | commentOnArrayElement4.ts | 23 AssertType([ /* element 1 */ 1, /* end of element 1 */], "number[]"); 25 /* element 1 */ 29 /* end of element 1 */
|
D | commentOnArrayElement9.ts | 23 AssertType([ /* element 1 */ 1, /* end of element 1 */], "number[]"); 25 /* element 1 */ 1, /* end of element 1 */
|
D | commentOnArrayElement7.ts | 21 const array = [/* element 1 */ 1, /* end of element 1 */]; 23 AssertType([/* element 1 */ 1, /* end of element 1 */], "number[]");
|
D | commentOnArrayElement5.ts | 23 AssertType([ /* element 1 */ 1, /* end of element 1 */ /* extra comment */], "number[]"… 25 /* element 1 */ 29 /* end of element 1 */
|
D | missingTypeArguments3.ts | 26 GroupBy<TKey>(keySelector: (element: T) => TKey): Enumerable<Grouping<TKey, T>>; 27 …GroupBy<TKey, TElement>(keySelector: (element: T) => TKey, elementSelector: (element: T) => TEleme… 28 ToDictionary<TKey>(keySelector: (element: T) => TKey): Dictionary<TKey, T>; 32 …ThenBy<TCompare>(keySelector: (element: T) => TCompare): OrderedEnumerable<T>; // used to incorrec…
|
/arkcompiler/runtime_core/docs/ |
D | assembly_format.md | 164 …element.name` | Used to specify name of the annotation element. `java.annotation.class` must be de… 165 …element.type` | Used to specify type of the annotation element. `java.annotation.element.name` mus… 166 …element.array.component.type` | Used to specify component type of the array annotation element. `j… 167 …n.element.value` | Used to specify value of the annotation element. Allowed multiple definitions (… 192 …element.name=NameArr, java.annotation.element.type=array, java.annotation.element.array.component.… 465 func_kv_pair := <an element of the function standard metadata list that assumes the assign… 466 func_id := <an element of the function standard metadata list> 469 func_kv_lonely_pair := <an element of the function lonely metadata list that assumes the assignme… 470 func_lonely_id := <an element of the function lonely metadata list> 477 rec_kv_pair := <an element of the record standard metadata list that assumes the assignmen… [all …]
|
/arkcompiler/ets_frontend/ts2panda/tests/expression/ |
D | propertyAccess.test.ts | 112 compilerunit.forEach(element => { 113 if (element.internalName === "func_main_0") { 114 let insns = element.getInsns(); 120 if (element.internalName === "myMethod") { 121 let parameterLength = element.getParameterLength(); 154 compilerunit.forEach(element => { 155 if (element.internalName === "func_main_0") { 156 let insns = element.getInsns(); 195 compilerunit.forEach(element => { 196 if (element.internalName === "func_main_0") { [all …]
|
/arkcompiler/ets_frontend/es2panda/util/ |
D | dumper.cpp | 32 std::visit([](auto&& element) { in DumpLiterals() argument 33 if constexpr (std::is_same_v<decltype(element), unsigned char &>) { in DumpLiterals() 34 std::cout << " val: " << unsigned(element) << std::endl; in DumpLiterals() 35 } else if constexpr (std::is_same_v<decltype(element), unsigned int &>) { in DumpLiterals() 36 std::cout << " val: " << signed(element) << std::endl; in DumpLiterals() 38 std::cout << " val: " << element << std::endl; in DumpLiterals()
|
/arkcompiler/ets_runtime/ecmascript/js_api/ |
D | js_api_linked_list.h | 53 const JSTaggedValue &element); 55 const JSTaggedValue &element); 57 bool Has(const JSTaggedValue &element); 61 JSTaggedValue Remove(JSThread *thread, const JSTaggedValue &element); 62 JSTaggedValue GetIndexOf(const JSTaggedValue &element); 63 JSTaggedValue GetLastIndexOf(const JSTaggedValue &element);
|
/arkcompiler/ets_runtime/ecmascript/ |
D | tagged_list.cpp | 144 int TaggedList<Derived>::FindIndexByElement(const JSTaggedValue &element) in FindIndexByElement() argument 153 if (JSTaggedValue::SameValue(data, element)) { in FindIndexByElement() 162 int TaggedList<Derived>::FindLastIndexByElement(const JSTaggedValue &element) in FindLastIndexByElement() argument 171 if (JSTaggedValue::SameValue(data, element)) { in FindLastIndexByElement() 246 int TaggedList<Derived>::FindPrevNodeByValue(const JSTaggedValue &element) in FindPrevNodeByValue() argument 254 if (JSTaggedValue::SameValue(data, element)) { in FindPrevNodeByValue() 340 bool TaggedSingleList::Has(const JSTaggedValue &element) in Has() argument 342 int dataIndex = FindIndexByElement(element); in Has() 361 int TaggedSingleList::GetIndexOf(const JSTaggedValue &element) in GetIndexOf() argument 363 return FindIndexByElement(element); in GetIndexOf() [all …]
|
D | tagged_list.h | 48 int FindIndexByElement(const JSTaggedValue &element); 49 int FindLastIndexByElement(const JSTaggedValue &element); 54 int FindPrevNodeByValue(const JSTaggedValue &element); 78 inline void SetElement(const JSThread *thread, int index, const JSTaggedValue &element) in SetElement() argument 83 Set(thread, index, element); in SetElement() 159 JSTaggedValue Remove(JSThread *thread, const JSTaggedValue &element); 184 const JSTaggedValue &element); 186 const JSTaggedValue &element); 197 JSTaggedValue Remove(JSThread *thread, const JSTaggedValue &element); 201 int FindPrevNodeByValueAtLast(const JSTaggedValue &element);
|