Home
last modified time | relevance | path

Searched refs:GetScope (Results 1 - 25 of 38) sorted by relevance

12

/arkcompiler/ets_frontend/ets2panda/compiler/lowering/scopesInit/
H A DsavedBindingsCtx.cpp29 for (const auto &[name, variable] : VarBinder()->GetScope()->OrderedBindings(Allocator())) { in BindImportDecl()
37 VarBinder()->GetScope()->AsModuleScope()->AddImportDecl(importDecl, std::move(declList)); in BindImportDecl()
52 if (VarBinder()->GetScope()->Bindings().size() == SavedBindings().size()) { in BindExportDecl()
63 for (const auto &[name, variable] : VarBinder()->GetScope()->Bindings()) { in BindExportDecl()
76 auto *moduleScope = VarBinder()->GetScope()->AsModuleScope(); in BindExportDecl()
H A DscopesInitPhase.cpp34 if (auto *var = varBinder->GetScope()->FindLocal(name, varbinder::ResolveBindingOptions::BINDINGS); in AddOrGetDecl()
45 HandleBlockStmt(program->Ast(), GetScope()); in Perform()
53 auto const *const curScope = VarBinder()->GetScope(); in VisitScriptFunction()
69 HandleBlockStmt(blockStmt, GetScope()); in VisitBlockStatement()
100 return lexicalScope.GetScope(); in HandleFunctionSig()
113 auto *functionScope = functionCtx.GetScope(); in HandleFunction()
140 auto *classScope = classCtx.GetScope(); in VisitClassDefinition()
158 lexicalScope.GetScope()->BindDecls(declCtx.GetScope()); in VisitForUpdateStatement()
159 HandleFor(declCtx.GetScope(), lexicalScop in VisitForUpdateStatement()
[all...]
H A DsavedBindingsCtx.h26 : varbinder_(varbinder), savedBindings_(varbinder_->GetScope()->Bindings()) in SavedBindingsContext()
H A DscopesInitPhase.h120 varbinder::Scope *GetScope() in GetScope() function in ark::es2panda::compiler::ScopesInitPhase
122 return VarBinder()->GetScope(); in GetScope()
/arkcompiler/ets_frontend/es2panda/parser/
H A Dcommonjs.cpp77 auto *funcParamScope = funcParamContext.LexicalScope().GetScope(); in ParseCommonjs()
83 auto *functionScope = functionCtx.GetScope(); in ParseCommonjs()
114 auto *blockStmt = AllocNode<ir::BlockStatement>(Binder()->GetScope(), std::move(statements)); in ParseCommonjs()
115 Binder()->GetScope()->BindNode(blockStmt); in ParseCommonjs()
H A DstatementParser.cpp399 auto *moduleDecl = AllocNode<ir::TSModuleDeclaration>(localCtx.GetScope(), name, body, isDeclare, isGlobal); in ParseTsAmbientExternalModuleDeclaration()
401 localCtx.GetScope()->BindNode(moduleDecl); in ParseTsAmbientExternalModuleDeclaration()
414 auto *parentScope = Binder()->GetScope(); in ParseTsModuleOrNamespaceDelaration()
453 auto *moduleDecl = AllocNode<ir::TSModuleDeclaration>(localCtx.GetScope(), identNode, body, in ParseTsModuleOrNamespaceDelaration()
456 localCtx.GetScope()->BindNode(moduleDecl); in ParseTsModuleOrNamespaceDelaration()
516 auto *scope = Binder()->GetScope(); in ParseTsImportEqualsDeclaration()
654 auto *localBlockStmt = AllocNode<ir::BlockStatement>(localCtx.GetScope(), std::move(stmts)); in ParseFunctionStatement()
656 localCtx.GetScope()->BindNode(localBlockStmt); in ParseFunctionStatement()
790 const auto &bindings = Binder()->GetScope()->Bindings(); in ParseTsInterfaceDeclaration()
824 AllocNode<ir::TSInterfaceDeclaration>(localScope.GetScope(), i in ParseTsInterfaceDeclaration()
[all...]
H A DparserImpl.cpp207 auto *blockStmt = AllocNode<ir::BlockStatement>(Binder()->GetScope(), std::move(statements)); in ParseProgram()
208 Binder()->GetScope()->BindNode(blockStmt); in ParseProgram()
1544 auto *funcParamScope = funcParamContext.LexicalScope().GetScope(); in ParseTsTypeLiteralOrInterfaceMember()
1935 auto *funcParamScope = funcParamContext.LexicalScope().GetScope(); in ParseTsFunctionType()
2666 auto *staticBlock = AllocNode<ir::ClassStaticBlock>(lexScope.GetScope(), blockStatement); in ParseStaticBlock()
2668 lexScope.GetScope()->BindNode(staticBlock); in ParseStaticBlock()
3021 auto *paramScope = Binder()->Allocator()->New<binder::FunctionParamScope>(Allocator(), Binder()->GetScope()); in CreateImplicitMethod()
3263 classCtx.GetScope(), identNode, typeParamDecl, superTypeParams, std::move(implements), ctor, staticInitializer, in ParseClassDefinition()
3271 classCtx.GetScope()->BindNode(classDefinition); in ParseClassDefinition()
3596 Binder()->GetScope() in ParseEnumMembers()
[all...]
/arkcompiler/ets_frontend/ets2panda/ast_verifier/
H A DimportExportAccessValid.cpp109 if (var->GetScope() != nullptr && var->GetScope()->Parent() != nullptr && in InvariantImportExportVariable()
110 var->GetScope()->Parent()->IsGlobalScope() && in InvariantImportExportVariable()
H A DvariableHasScope.cpp35 const auto scope = var->GetScope(); in operator ()()
85 const auto scope = var->GetScope(); in ScopeEncloseVariable()
H A DcheckScopeDeclaration.cpp36 auto const *const scope = var->GetScope(); in operator ()()
H A DvariableHasEnclosingScope.cpp33 const auto scope = var->GetScope(); in operator ()()
/arkcompiler/ets_frontend/ets2panda/ir/expressions/
H A DarrowFunctionExpression.cpp148 return Function()->Scope()->IsSuperscopeOf(var->GetScope()) || in IsVarFromSubscope()
149 Function()->Scope()->ParamScope()->IsSuperscopeOf(var->GetScope()); in IsVarFromSubscope()
/arkcompiler/ets_frontend/ets2panda/compiler/lowering/
H A Dutil.cpp98 auto *sc = var->GetScope();
99 if (sc != nullptr && !sc->IsClassScope() && !sc->IsGlobalScope() && scopes.count(var->GetScope()) == 0) {
/arkcompiler/ets_frontend/ets2panda/varbinder/
H A DETSBinder.cpp72 ASSERT(GetScope() == TopScope()); in IdentifierAnalysis()
107 auto *iter = GetScope(); in LookupTypeReference()
208 auto res = GetScope()->Find(name, ResolveBindingOptions::ALL); in LookupIdentReference()
212 auto *outerFunction = GetScope()->EnclosingVariableScope()->Node(); in LookupIdentReference()
237 auto res = GetScope()->Find(decl->Id()->Name()); in InitializeInterfaceIdent()
429 ASSERT(GetScope()->Find(name, ResolveBindingOptions::DECLARATION).variable != nullptr); in AddDynamicSpecifiersToTopBindings()
430 auto specDecl = GetScope()->Find(name, ResolveBindingOptions::DECLARATION); in AddDynamicSpecifiersToTopBindings()
465 Scope *scope = var->GetScope(); in GetPackageName()
1121 auto *const var = scopeCtx.GetScope()->FindLocal(name, ResolveBindingOptions::ALL); in ImportGlobalProperties()
H A Dvarbinder.h113 Scope *GetScope() const in GetScope() function in ark::es2panda::ark::es2panda::ark::es2panda::ark::es2panda::varbinder::VarBinder
288 T *GetScope() const in GetScope() function in ark::es2panda::ark::es2panda::ark::es2panda::ark::es2panda::varbinder::LexicalScope
H A Dvariable.h101 [[nodiscard]] Scope *GetScope() const noexcept
/arkcompiler/ets_frontend/es2panda/ir/statements/
H A DblockStatement.cpp67 scope_ != nullptr ? scope_ : binder->GetScope()); in UpdateSelf()
/arkcompiler/ets_frontend/ets2panda/evaluate/
H A DvarbinderScopes.h34 prevScope_(varBinder->GetScope()) in ProgramScope()
H A Dhelpers.cpp282 binderScope_(varBinder->GetScope()), in SafeStateScope()
301 ASSERT(binderScope_ == varBinder_->GetScope()); in ~SafeStateScope()
/arkcompiler/ets_frontend/ets2panda/compiler/lowering/ets/
H A DcapturedVariables.cpp56 auto *scope = var->GetScope();
H A DboxingForLocals.cpp66 auto *scope = var->GetScope(); in FindCaptured()
180 auto *scope = oldVar->GetScope(); in HandleVariableDeclarator()
282 auto *scope = newVar->GetScope(); in HandleAssignment()
H A DenumLowering.cpp189 classDef->SetScope(classCtx.GetScope()); in CreateClass()
737 var->SetScope(elp->Varbinder()->GetScope());
824 loopScope.GetScope()->BindDecls(loopDeclScope.GetScope());
827 loopScope.GetScope()->BindNode(forLoop);
828 forLoop->SetScope(loopScope.GetScope());
829 loopScope.GetScope()->DeclScope()->BindNode(forLoop);
/arkcompiler/ets_frontend/es2panda/binder/
H A Dbinder.cpp666 loopCtx.GetScope()->InitVariable(); in BuildForUpdateLoop()
678 loopCtx.GetScope()->InitVariable(); in BuildForInOfLoop()
863 LexicalScope<Scope>::Enter(this, GetScope()); in ResolveReference()
884 loopScopeCtx.GetScope()->InitVariable(); in ResolveReference()
896 loopScopeCtx.GetScope()->InitVariable(); in ResolveReference()
1028 auto *scope = GetScope(); in AddDeclarationName()
H A Dbinder.h86 Scope *GetScope() const in GetScope() function in panda::es2panda::panda::es2panda::binder::Binder
257 T *GetScope() const in GetScope() function in panda::es2panda::panda::es2panda::binder::LexicalScope
/arkcompiler/ets_frontend/ets2panda/checker/ets/
H A Dfunction.cpp1729 !var->HasFlag(varbinder::VariableFlags::LOCAL) || var->GetScope()->Node()->IsArrowFunctionExpression()) { in CheckCapturedVariables()
1882 var->SetScope(ctx.GetScope()); in CreateFuncDecl()
1971 var->SetScope(paramCtx.GetScope()); in CopyParams()
1979 return paramCtx.GetScope(); in CopyParams()
2028 auto *funcParamScope = varbinder::LexicalScope<varbinder::FunctionParamScope>(VarBinder()).GetScope(); in TransformTraillingLambda()
2032 auto *funcScope = funcCtx.GetScope(); in TransformTraillingLambda()
2039 if (var->GetScope() == trailingBlock->Scope()) { in TransformTraillingLambda()
2069 auto *funcScope = funcCtx.GetScope(); in ExtendArgumentsWithFakeLamda()

Completed in 27 milliseconds

12