| /arkcompiler/runtime_core/static_core/plugins/ets/templates/stdlib/ |
| D | typedUArray.sts.j2 | 24 {%- for element in [{'name': 'Uint8Clamped', 'subsetType': 'number', 'subsetTypeValues': 'Number', … 29 …element.update({'subsetTypeBoxed': element['subsetType'][0].upper() + element['subsetType'][1:], … 30 …{%- set asElementCompat = ('%s as ' + element['subsetType']) if element['subsetType'] != 'BigInt' … 31 …{%- set fromElementCompat = ('%s as ' + element['primitiveType']) if element['subsetType'] != 'Big… 32 …{%- set numberBigIntToPrimitive = ('.' + element['primitiveType'] + 'Value()') if element['subsetT… 34 …{%- set isNonCompat = '/* public */ internal' if element['subsetType'] != 'BigInt' else 'private' … 35 …{%- set valueOrBigIntGetULong = '%s' if element['subsetType'] != 'BigInt' else 'new BigInt(%s).get… 36 …{%- set asElementCompatOrBigInt = ('%s as ' + element['primitiveType']) if element['subsetType'] !… 38 class {{element['name']}}ArrayIteratorKeys implements IterableIterator<number> { 42 constructor(parent: {{element['name']}}Array) { [all …]
|
| D | Array_builtin_algorithms.sts.j2 | 36 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 74 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 89 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 127 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 142 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 180 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 195 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 233 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is…
|
| /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/es2panda/compiler/base/ |
| D | destructuring.cpp | 40 // create left reference for rest element in GenRestElement() 80 for (const auto *element : array->Elements()) { in GenArray() local 83 if (element->IsRestElement()) { in GenArray() 84 GenRestElement(pg, element->AsRestElement(), iterator, array->IsDeclaration()); in GenArray() 89 if (element->IsOmittedExpression()) { in GenArray() 95 const ir::Expression *target = element; in GenArray() 97 if (element->IsAssignmentPattern() || element->IsAssignmentExpression()) { in GenArray() 98 auto *assignment = element->IsAssignmentPattern() ? element->AsAssignmentPattern() : in GenArray() 99 element->AsAssignmentExpression(); in GenArray() 110 pg->BranchIfStrictUndefined(element, defaultInit); in GenArray() [all …]
|
| D | literals.cpp | 44 for (const auto *element : templateLit->Quasis()) { in GetTemplateObject() local 45 pg->LoadAccumulatorInt(element, elemIndex); in GetTemplateObject() 46 pg->StoreAccumulator(element, indexReg); in GetTemplateObject() 48 pg->LoadAccumulatorString(element, element->Raw()); in GetTemplateObject() 49 pg->DefineFieldByValue(element, rawArr, indexReg); in GetTemplateObject() 50 // Generate ldundefined when element is escape error in GetTemplateObject() 51 if (element->EscapeError()) { in GetTemplateObject() 52 pg->LoadConst(element, compiler::Constant::JS_UNDEFINED); in GetTemplateObject() 54 pg->LoadAccumulatorString(element, element->Cooked()); in GetTemplateObject() 56 pg->DefineFieldByValue(element, cookedArr, indexReg); in GetTemplateObject()
|
| /arkcompiler/ets_frontend/ets2panda/compiler/base/ |
| D | destructuring.cpp | 42 // create left reference for rest element in GenRestElement() 73 for (const auto *element : array->Elements()) { in GenElement() local 76 if (element->IsRestElement()) { in GenElement() 77 GenRestElement(pg, element->AsRestElement(), iterator, array->IsDeclaration()); in GenElement() 82 if (element->IsOmittedExpression()) { in GenElement() 88 const ir::Expression *target = element; in GenElement() 90 if (element->IsAssignmentPattern()) { in GenElement() 91 target = element->AsAssignmentPattern()->Left(); in GenElement() 92 init = element->AsAssignmentPattern()->Right(); in GenElement() 101 pg->BranchIfUndefined(element, defaultInit); in GenElement() [all …]
|
| D | literals.cpp | 42 for (const auto *element : templateLit->Quasis()) { in GetTemplateObject() local 43 pg->LoadAccumulatorInt(element, elemIndex); in GetTemplateObject() 44 pg->StoreAccumulator(element, indexReg); in GetTemplateObject() 46 pg->LoadAccumulatorString(element, element->Raw()); in GetTemplateObject() 47 pg->StoreObjByValue(element, rawArr, indexReg); in GetTemplateObject() 49 pg->LoadAccumulatorString(element, element->Cooked()); in GetTemplateObject() 50 pg->StoreObjByValue(element, cookedArr, indexReg); in GetTemplateObject()
|
| /arkcompiler/ets_frontend/ets2panda/test/ast/compiler/ets/annotation_tests/ |
| D | annotationDecl_bad_initializer08.sts | 29 /* @@? 22:29 Error TypeError: Array element type 'double' is not assignable to explicit type 'int' … 30 /* @@? 22:34 Error TypeError: Array element type 'double' is not assignable to explicit type 'int' … 31 … @@? 22:29 Error TypeError: Array element at index 0 with type 'double' is not compatible with the… 32 … @@? 22:34 Error TypeError: Array element at index 1 with type 'double' is not compatible with the… 35 /* @@? 24:30 Error TypeError: Array element type 'Color' is not assignable to explicit type 'Size' … 36 /* @@? 24:43 Error TypeError: Array element type 'Color' is not assignable to explicit type 'Size' … 37 … @@? 24:30 Error TypeError: Array element at index 0 with type 'Color' is not compatible with the … 38 … @@? 24:43 Error TypeError: Array element at index 1 with type 'Color' is not compatible with the …
|
| D | annotationUsage_bad_param09.sts | 40 … @@? 31:25 Error TypeError: Array element at index 0 with type 'double' is not compatible with the… 41 … @@? 31:30 Error TypeError: Array element at index 1 with type 'double' is not compatible with the… 44 … @@? 33:25 Error TypeError: Array element at index 0 with type 'Color' is not compatible with the … 45 … @@? 33:38 Error TypeError: Array element at index 1 with type 'Color' is not compatible with the …
|
| /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/runtime_core/static_core/libpandabase/utils/ |
| D | ring_buffer.h | 149 * Appends the given element value to the end of the ring buffer 150 * @param value the value of the element to append 159 * Moves the given element value to the end of the ring buffer 160 * @param value the value of the element to append 168 * Appends a new element to the end of the ring buffer 171 * @param args arguments to forward to the constructor of the element 172 * @return a reference to the inserted element 183 * Appends the given element value to the begin of the ring buffer 184 * @param value the value of the element to append 193 * Moves the given element value to the begin of the ring buffer [all …]
|
| /arkcompiler/ets_runtime/test/moduletest/typedarrayfindlast/ |
| D | typedarrayfindlast.js | 79 let result1 = obj.findLast((element, index, array) => { 80 return (element == 12); 83 result1 = obj.findLast((element, index, array) => { 84 return (element < 10); 87 result1 = obj.findLastIndex((element, index, array) => { 91 return (element == 100); 94 result1 = obj.findLastIndex((element, index, array) => { 95 return (element == 100); 109 let result1 = obj.findLast((element, index, array) => { 110 return (element == 12n); [all …]
|
| /arkcompiler/runtime_core/static_core/runtime/include/ |
| D | histogram-inl.h | 46 void SimpleHistogram<Value>::AddValue(const Value &element, size_t number) in AddValue() argument 48 sum_ += element * Value(number); in AddValue() 49 sumOfSquares_ += element * element * Value(number); in AddValue() 51 min_ = element; in AddValue() 52 max_ = element; in AddValue() 54 min_ = std::min(min_, element); in AddValue() 55 max_ = std::max(max_, element); in AddValue() 89 void Histogram<Value>::AddValue(const Value &element, size_t number) in AddValue() argument 91 frequency_[element] += number; in AddValue() 92 SimpleHistogram<Value>::AddValue(element, number); in AddValue()
|
| /arkcompiler/ets_runtime/test/moduletest/arrayFindIndexCase/ |
| D | findIndex.js | 24 const isLargeNumber = (element) => element > 13; argument 35 function isPrime(element) { argument 36 if (element % 2 === 0 || element < 2) { 39 for (let factor = 3; factor <= Math.sqrt(element); factor += 2) { 40 if (element % factor === 0) { 64 const hasFirst = (element) => element == "first"; argument
|
| /arkcompiler/ets_runtime/test/aottest/array_foreach_inline/ |
| D | array_foreach_inline.ts | 18 array1.forEach((element) => { 19 print(element) 22 array1.forEach((element) => { 24 print(element) 27 array1.forEach((element) => { 29 print(element)
|
| /arkcompiler/runtime_core/static_core/plugins/ets/stdlib/std/core/ |
| D | BuiltinArray.sts | 82 * @param index Zero-based index of the array element to be returned. 85 * @returns The element in the array matching the given index. 132 * @param index Zero-based index of the array element to be returned. 135 * @returns The element in the array matching the given index. 274 * Returns the value of the first element in the array where predicate is true, and undefined 277 * @param predicate find calls predicate once for each element of the array, in ascending 278 * order, until it finds one where predicate returns true. If such an element is found, find 279 * immediately returns that element value. Otherwise, find returns undefined. 281 * @returns the value of the first element in the array or undefined 292 * Returns the index of the first element in the array where predicate is true, and -1 [all …]
|
| D | BuiltinArrayAlgorithms.sts | 32 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 70 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 85 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 123 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 198 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 236 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 251 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 289 …* Upper bound is an index of a first element, where (key < element) is true. If no such element is… 364 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… 402 …* Lower bound is an index of a first element, where (element < key) is false. If no such element i… [all …]
|
| /arkcompiler/runtime_core/static_core/runtime/ |
| D | compiler_queue_counter_priority.h | 96 auto element = queue_.back(); in GetTask() local 97 auto task = std::move(element->GetContext()); in GetTask() 99 allocator_->Delete(element); in GetTask() 119 …LOG(DEBUG, COMPILATION_QUEUE) << "Add an element to a " << queueName_ << ": " << GetTaskDescriptio… 120 auto element = allocator_->New<CompilationQueueElement>(std::move(ctx)); variable 122 queue_.push_back(element); 140 virtual bool UpdateCounterAndCheck(CompilationQueueElement *element) in UpdateCounterAndCheck() argument 143 element->UpdateCounter(element->GetContext().GetMethod()->GetHotnessCounter()); in UpdateCounterAndCheck() 145 return (curStamp - element->GetTimestamp() >= taskLifeSpan_); in UpdateCounterAndCheck() 178 auto element = *it; in UpdateQueue() local [all …]
|
| /arkcompiler/ets_runtime/test/moduletest/arrayfindlastindex/ |
| D | arrayfindlastindex.js | 33 function testFunction(element, index, array) { argument 37 return element < 1; 50 function fun1(element) { argument 51 return element === 1; 60 function func2(element, index, arr) { argument 61 return element === 6; 67 function func3(element, index, arr) { argument 69 return element === 100;
|
| /arkcompiler/ets_frontend/arkguard/test/grammar/wildcard_comment/keep_comment3/ |
| D | keep_single_comment.d.ts | 27 * Pushes an element onto the stack. 28 * @param {T} element - The element to push. 30 B(element: T): void; 33 * Pops an element from the stack. 34 * @returns {T} The popped element.
|
| /arkcompiler/ets_frontend/arkguard/test/grammar/wildcard_comment/keep_comment2/ |
| D | keep_all_comment_expected.txt | 22 * Pushes an element onto the stack. 23 * @param {T} element - The element to push. 25 push(element: T): void; 27 * Pops an element from the stack. 28 * @returns {T} The popped element.
|
| D | keep_all_comment.d.ts | 27 * Pushes an element onto the stack. 28 * @param {T} element - The element to push. 30 push(element: T): void; 33 * Pops an element from the stack. 34 * @returns {T} The popped element.
|
| /arkcompiler/ets_frontend/arkguard/test/grammar/removeComments/ |
| D | removeComments2.d.ts | 27 * Pushes an element onto the stack. 28 * @param {T} element - The element to push. 30 push(element: T): void; 33 * Pops an element from the stack. 34 * @returns {T} The popped element.
|
| /arkcompiler/ets_runtime/test/moduletest/arrayflatmap/ |
| D | arrayflatmap.js | 40 function testFunction(element, index, array) { argument 44 return [element, element * element]; 58 function testFunction(element, index, array) { 65 return [element, element * element];
|
| /arkcompiler/runtime_core/static_core/plugins/ets/stdlib/escompat/ |
| D | TypedArrays.sts | 349 * Assigns val as element on index. 360 * Assigns val as element on index. 376 * Assigns val as element on index. 387 * Assigns val as element on index. 403 * Assigns val as element on index. 414 * Assigns val as element on index. 748 * Assigns val as element on insertPos. 760 * Assigns val as element on insertPos. 919 * @param mapfn A mapping function to call on every element of the array. 973 * @param mapfn A mapping function to call on every element of the array. [all …]
|