Home
last modified time | relevance | path

Searched refs:TypeAnnotation (Results 1 – 25 of 61) sorted by relevance

123

/arkcompiler/ets_frontend/ets2panda/ir/expressions/
Didentifier.cpp53 if (TypeAnnotation() != nullptr) { in TransformChildren()
54 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
64 if (TypeAnnotation() != nullptr) { in Iterate()
65 cb(TypeAnnotation()); in Iterate()
79 if (TypeAnnotation() != nullptr) { in ValidateExpression()
80 return {"Unexpected token.", TypeAnnotation()->Start()}; in ValidateExpression()
91 {"typeAnnotation", AstDumper::Optional(TypeAnnotation())}, in Dump()
DobjectExpression.cpp86 if (TypeAnnotation() != nullptr) { in ValidateExpression()
87 return {"Unexpected token.", TypeAnnotation()->Start()}; in ValidateExpression()
204 if (TypeAnnotation() != nullptr) { in TransformChildren()
205 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
219 if (TypeAnnotation() != nullptr) { in Iterate()
220 cb(TypeAnnotation()); in Iterate()
229 {"typeAnnotation", AstDumper::Optional(TypeAnnotation())}, in Dump()
DarrayExpression.cpp125 if (TypeAnnotation() != nullptr) { in ValidateExpression()
126 return {"Unexpected token.", TypeAnnotation()->Start()}; in ValidateExpression()
179 if (TypeAnnotation() != nullptr) { in TransformChildren()
180 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
194 if (TypeAnnotation() != nullptr) { in Iterate()
195 cb(TypeAnnotation()); in Iterate()
204 {"typeAnnotation", AstDumper::Optional(TypeAnnotation())}, in Dump()
/arkcompiler/ets_frontend/ets2panda/ir/base/
DtsPropertySignature.cpp28 if (TypeAnnotation() != nullptr) { in TransformChildren()
29 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
37 if (TypeAnnotation() != nullptr) { in Iterate()
38 cb(TypeAnnotation()); in Iterate()
49 {"typeAnnotation", AstDumper::Optional(TypeAnnotation())}}); in Dump()
81 auto *const typeAnnotation = TypeAnnotation()->Clone(allocator); in Clone()
DspreadElement.cpp118 if (TypeAnnotation() != nullptr) { in TransformChildren()
119 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
131 if (TypeAnnotation() != nullptr) { in Iterate()
132 cb(TypeAnnotation()); in Iterate()
141 {"typeAnnotation", AstDumper::Optional(TypeAnnotation())}}); in Dump()
148 auto type = TypeAnnotation(); in Dump()
/arkcompiler/ets_frontend/ets2panda/ir/ts/
DtsTypeAliasDeclaration.cpp45 if (TypeAnnotation() != nullptr) { in TransformChildren()
46 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
62 if (TypeAnnotation() != nullptr) { in Iterate()
63 cb(TypeAnnotation()); in Iterate()
72 {"typeAnnotation", TypeAnnotation()}, in Dump()
89 auto type = TypeAnnotation(); in Dump()
DtsTypeAssertion.cpp28 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
34 cb(TypeAnnotation()); in Iterate()
40 …dumper->Add({{"type", "TSTypeAssertion"}, {"typeAnnotation", TypeAnnotation()}, {"expression", exp… in Dump()
DtsAsExpression.cpp47 SetTsTypeAnnotation(static_cast<TypeNode *>(cb(TypeAnnotation()))); in TransformChildren()
53 cb(TypeAnnotation()); in Iterate()
58 …d({{"type", "TSAsExpression"}, {"expression", expression_}, {"typeAnnotation", TypeAnnotation()}}); in Dump()
/arkcompiler/ets_frontend/ets2panda/ir/ets/
DetsParameterExpression.cpp84 TypeNode const *ETSParameterExpression::TypeAnnotation() const noexcept in TypeAnnotation() function in panda::es2panda::ir::ETSParameterExpression
86 return !IsRestParameter() ? ident_->TypeAnnotation() : spread_->TypeAnnotation(); in TypeAnnotation()
89 TypeNode *ETSParameterExpression::TypeAnnotation() noexcept in TypeAnnotation() function in panda::es2panda::ir::ETSParameterExpression
91 return !IsRestParameter() ? ident_->TypeAnnotation() : spread_->TypeAnnotation(); in TypeAnnotation()
154 auto typeAnnotation = ident_->AsAnnotatedExpression()->TypeAnnotation(); in Dump()
DetsParameterExpression.h58 [[nodiscard]] TypeNode const *TypeAnnotation() const noexcept;
59 [[nodiscard]] TypeNode *TypeAnnotation() noexcept;
/arkcompiler/ets_frontend/es2panda/ir/statements/
DvariableDeclarator.cpp76 const ir::Expression *typeAnnotation = declarator->Id()->AsIdentifier()->TypeAnnotation(); in CheckSimpleVariableDeclaration()
134 …:ArrayDestructuringContext(checker, id_, false, id_->AsArrayPattern()->TypeAnnotation() == nullptr, in Check()
135 id_->AsArrayPattern()->TypeAnnotation(), init_) in Check()
144 …checker::ObjectDestructuringContext(checker, id_, false, id_->AsObjectPattern()->TypeAnnotation() … in Check()
145 id_->AsObjectPattern()->TypeAnnotation(), init_) in Check()
/arkcompiler/ets_frontend/es2panda/ir/base/
DcatchClause.cpp65 typeAnnotation = param_->AsIdentifier()->TypeAnnotation(); in Check()
67 typeAnnotation = param_->AsArrayPattern()->TypeAnnotation(); in Check()
70 typeAnnotation = param_->AsObjectPattern()->TypeAnnotation(); in Check()
/arkcompiler/ets_frontend/es2panda/typescript/core/
Dfunction.cpp128 if (!param->TypeAnnotation()) { in CheckFunctionIdentifierParameter()
136 param->TypeAnnotation()->Check(this); in CheckFunctionIdentifierParameter()
137 paramVar->SetTsType(param->TypeAnnotation()->AsTypeNode()->GetType(this)); in CheckFunctionIdentifierParameter()
214 if (paramIdent->TypeAnnotation()) { in CheckFunctionAssignmentPatternParameter()
215 paramIdent->TypeAnnotation()->Check(this); in CheckFunctionAssignmentPatternParameter()
216 Type *paramType = paramIdent->TypeAnnotation()->AsTypeNode()->GetType(this); in CheckFunctionAssignmentPatternParameter()
235 …ArrayDestructuringContext(this, arrayPattern, false, true, arrayPattern->TypeAnnotation(), param->… in CheckFunctionAssignmentPatternParameter()
241 …ext = ObjectDestructuringContext(this, objectPattern, false, true, objectPattern->TypeAnnotation(), in CheckFunctionAssignmentPatternParameter()
262 typeAnnotation = param->Argument()->AsIdentifier()->TypeAnnotation(); in CheckFunctionRestParameter()
266 typeAnnotation = param->Argument()->AsArrayPattern()->TypeAnnotation(); in CheckFunctionRestParameter()
[all …]
Dhelpers.cpp343 if (declarator->Id()->AsIdentifier()->TypeAnnotation()) { in InferSimpleVariableDeclaratorType()
344 … var->SetTsType(declarator->Id()->AsIdentifier()->TypeAnnotation()->AsTypeNode()->GetType(this)); in InferSimpleVariableDeclaratorType()
396 …var->SetTsType(decl->Node()->AsTSPropertySignature()->TypeAnnotation()->AsTypeNode()->GetType(this… in GetTypeOfVariable()
415 if (ident->TypeAnnotation()) { in GetTypeOfVariable()
417 var->SetTsType(ident->TypeAnnotation()->AsTypeNode()->GetType(this)); in GetTypeOfVariable()
427 if (ident->TypeAnnotation()) { in GetTypeOfVariable()
429 var->SetTsType(ident->TypeAnnotation()->AsTypeNode()->GetType(this)); in GetTypeOfVariable()
492 resolvedType = declaration->TypeAnnotation()->AsTypeNode()->GetType(this); in GetTypeFromTypeAliasReference()
/arkcompiler/ets_frontend/es2panda/ir/expressions/
DprivateIdentifier.h47 const Expression *TypeAnnotation() const in TypeAnnotation() function
52 Expression *TypeAnnotation() in TypeAnnotation() function
DarrayExpression.h46 const Expression *TypeAnnotation() const in TypeAnnotation() function
51 Expression *TypeAnnotation() in TypeAnnotation() function
Didentifier.h60 const Expression *TypeAnnotation() const in DEFINE_BITOPS()
65 Expression *TypeAnnotation() in DEFINE_BITOPS()
DobjectExpression.h54 const Expression *TypeAnnotation() const in TypeAnnotation() function
59 Expression *TypeAnnotation() in TypeAnnotation() function
/arkcompiler/ets_frontend/es2panda/ir/ts/
DtsIndexSignature.h55 const Expression *TypeAnnotation() const in TypeAnnotation() function
60 Expression *TypeAnnotation() in TypeAnnotation() function
DtsTypeAssertion.h39 const Expression *TypeAnnotation() const in TypeAnnotation() function
DtsSatisfiesExpression.h52 const Expression *TypeAnnotation() const in TypeAnnotation() function
/arkcompiler/ets_frontend/ets2panda/checker/ts/
Dfunction.cpp126 if (param->TypeAnnotation() == nullptr) { in CheckFunctionIdentifierParameter()
134 param->TypeAnnotation()->Check(this); in CheckFunctionIdentifierParameter()
135 paramVar->SetTsType(param->TypeAnnotation()->GetType(this)); in CheckFunctionIdentifierParameter()
212 if (paramIdent->TypeAnnotation() != nullptr) { in CheckFunctionAssignmentPatternParameter()
213 paramIdent->TypeAnnotation()->Check(this); in CheckFunctionAssignmentPatternParameter()
214 Type *paramType = paramIdent->TypeAnnotation()->GetType(this); in CheckFunctionAssignmentPatternParameter()
233 …ArrayDestructuringContext(this, arrayPattern, false, true, arrayPattern->TypeAnnotation(), param->… in CheckFunctionAssignmentPatternParameter()
239 …ext = ObjectDestructuringContext(this, objectPattern, false, true, objectPattern->TypeAnnotation(), in CheckFunctionAssignmentPatternParameter()
259 typeAnnotation = param->Argument()->AsAnnotatedExpression()->TypeAnnotation(); in CheckFunctionRestParameter()
313 if (param->TypeAnnotation() != nullptr) { in CheckFunctionArrayPatternParameter()
[all …]
Dhelpers.cpp344 if (declarator->Id()->AsIdentifier()->TypeAnnotation() != nullptr) { in InferSimpleVariableDeclaratorType()
345 var->SetTsType(declarator->Id()->AsIdentifier()->TypeAnnotation()->GetType(this)); in InferSimpleVariableDeclaratorType()
397 var->SetTsType(decl->Node()->AsTSPropertySignature()->TypeAnnotation()->GetType(this)); in GetTypeOfVariable()
416 if (ident->TypeAnnotation() != nullptr) { in GetTypeOfVariable()
418 var->SetTsType(ident->TypeAnnotation()->GetType(this)); in GetTypeOfVariable()
428 if (ident->TypeAnnotation() != nullptr) { in GetTypeOfVariable()
430 var->SetTsType(ident->TypeAnnotation()->GetType(this)); in GetTypeOfVariable()
493 resolvedType = declaration->TypeAnnotation()->GetType(this); in GetTypeFromTypeAliasReference()
/arkcompiler/ets_frontend/ets2panda/ir/
Dexpression.cpp24 if (auto *const annotation = other.TypeAnnotation(); annotation != nullptr) { in AnnotatedExpression()
/arkcompiler/ets_frontend/ets2panda/compiler/lowering/ets/
DinterfacePropertyDeclarations.cpp49 paramIdent->SetTsTypeAnnotation(field->TypeAnnotation()->Clone(checker->Allocator())); in GenerateGetterOrSetter()
50 paramIdent->TypeAnnotation()->SetParent(paramIdent); in GenerateGetterOrSetter()
64 … = ir::FunctionSignature(nullptr, std::move(params), isSetter ? nullptr : field->TypeAnnotation()); in GenerateGetterOrSetter()

123