/arkcompiler/ets_frontend/ts2panda/src/base/ |
D | builtIn.ts | 16 import { PandaGen } from "src/pandagen"; 33 export function expandHole(pandaGen: PandaGen): IRNode[] { 41 export function expandNaN(pandaGen: PandaGen): IRNode[] { 49 export function expandInfinity(pandaGen: PandaGen): IRNode[] { 57 export function expandGlobal(pandaGen: PandaGen): IRNode[] { 65 export function expandUndefined(pandaGen: PandaGen): IRNode[] { 73 export function expandSymbol(pandaGen: PandaGen): IRNode[] { 81 export function expandNull(pandaGen: PandaGen): IRNode[] { 89 export function expandTrue(pandaGen: PandaGen): IRNode[] { 97 export function expandFalse(pandaGen: PandaGen): IRNode[] { [all …]
|
/arkcompiler/ets_frontend/es2panda/compiler/core/ |
D | pandagen.cpp | 53 void PandaGen::SetFunctionKind() in SetFunctionKind() 98 Label *PandaGen::AllocLabel() in AllocLabel() 104 bool PandaGen::IsDebug() const in IsDebug() 109 bool PandaGen::isDebuggerEvaluateExpressionMode() const in isDebuggerEvaluateExpressionMode() 114 std::string PandaGen::SourceFile() const in SourceFile() 119 uint32_t PandaGen::ParamCount() const in ParamCount() 128 uint32_t PandaGen::FormalParametersCount() const in FormalParametersCount() 139 uint32_t PandaGen::InternalParamCount() const in InternalParamCount() 147 const util::StringView &PandaGen::InternalName() const in InternalName() 152 const util::StringView &PandaGen::FunctionName() const in FunctionName() [all …]
|
D | envScope.h | 32 class PandaGen; variable 36 explicit ScopeContext(PandaGen *pg, binder::Scope *newScope); 43 PandaGen *pg_; 55 void Initialize(PandaGen *pg); 63 friend class PandaGen; 65 PandaGen *pg_ {}; 71 explicit LoopEnvScope(PandaGen *pg, binder::LoopScope *scope, LabelTarget target) in LoopEnvScope() 77 explicit LoopEnvScope(PandaGen *pg, LabelTarget target, binder::LoopScope *scope) in LoopEnvScope() 104 void InitLoopContext(PandaGen *pg, binder::VariableScope *scope);
|
D | regScope.h | 29 class PandaGen; variable 33 explicit RegScope(PandaGen *pg); 44 PandaGen *pg_; 50 explicit LocalRegScope(PandaGen *pg, binder::Scope *scope); 51 explicit LocalRegScope(PandaGen *pg); 65 explicit LoopRegScope(PandaGen *pg, binder::LoopScope *scope); 79 explicit FunctionRegScope(PandaGen *pg);
|
D | dynamicContext.h | 31 class PandaGen; variable 78 explicit DynamicContext(PandaGen *pg, LabelTarget target); 80 PandaGen *pg_; 87 explicit LabelContext(PandaGen *pg, LabelTarget target) : DynamicContext(pg, target) {} in LabelContext() 88 explicit LabelContext(PandaGen *pg, const ir::LabelledStatement *labelledStmt); 105 explicit LexEnvContext(LoopEnvScope *envScope, PandaGen *pg, LabelTarget target); 126 explicit IteratorContext(PandaGen *pg, const Iterator &iterator, LabelTarget target); 156 explicit DestructuringIteratorContext(PandaGen *pg, const DestructuringIterator &iterator); 185 explicit TryContext(PandaGen *pg, const ir::TryStatement *tryStmt, bool hasFinalizer = true) 192 explicit TryContext(PandaGen *pg) : DynamicContext(pg, {}) in TryContext()
|
/arkcompiler/ets_frontend/ts2panda/tests/expression/ |
D | binary.test.ts | 55 import { PandaGen } from '../../src/pandagen'; 60 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("2 + 3"), 0, undefined); 74 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("5 - 1"), 0, undefined); 88 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("null ?? 1"), 0, undefined); 117 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("undefined ?? 1"), 0, undefined); 147 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("2 ?? 1"), 0, undefined); 178 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 * 4"), 0, undefined); 192 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("2 ** 3"), 0, undefined); 206 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("7 / 1"), 0, undefined); 220 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("8 % 2"), 0, undefined); [all …]
|
D | numericLiteral.test.ts | 26 import { PandaGen } from "../../src/pandagen"; 32 let pandaGen = new PandaGen("ignored", creatAstFromSnippet("NaN"), 0, undefined); 41 let pandaGen = new PandaGen("ignored", creatAstFromSnippet("10e10000"), 0, undefined); 49 let pandaGen = new PandaGen("ignored", creatAstFromSnippet("1"), 0, undefined); 57 let pandaGen = new PandaGen("ignored", creatAstFromSnippet("2147483648"), 0, undefined); 65 let pandaGen = new PandaGen("ignored", creatAstFromSnippet("1.1"), 0, undefined);
|
D | operationEqual.test.ts | 42 import { PandaGen } from '../../src/pandagen'; 49 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 2;\n" + 69 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 5;\n" + 89 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 2;\n" + 109 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 2;\n" + 129 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 5;\n" + 149 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 5;\n" + 169 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 8;\n" + 189 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 4;\n" + 210 IRNode.pg = new PandaGen("", creatAstFromSnippet("let a = 8;\n" +
|
D | cmpBinary.test.ts | 53 import { PandaGen } from '../../src/pandagen'; 58 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("2 < 3;"), 0, undefined); 81 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 > 1;"), 0, undefined); 104 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 <= 4;"), 0, undefined); 127 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 >= 2;"), 0, undefined); 150 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 == 3;"), 0, undefined); 173 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 != 2;"), 0, undefined); 196 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 === 3;"), 0, undefined); 219 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("3 !== 3;"), 0, undefined); 243 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let a = 5;\n" + "a &= 3;"), 0, undefined); [all …]
|
D | literal.test.ts | 23 import { PandaGen } from '../../src/pandagen'; 97 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 112 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 127 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 143 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 162 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 183 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 214 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 230 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 245 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); [all …]
|
D | typeOf.test.ts | 36 import { PandaGen } from '../../src/pandagen'; 41 IRNode.pg = new PandaGen("", creatAstFromSnippet("typeof 5"), 0, undefined); 54 IRNode.pg = new PandaGen("", creatAstFromSnippet("typeof Number(\"5\")"), 0, undefined); 75 IRNode.pg = new PandaGen("", creatAstFromSnippet("typeof x"), 0, undefined); 89 IRNode.pg = new PandaGen("", creatAstFromSnippet("typeof(x)"), 0, undefined);
|
D | prefixOperations.test.ts | 43 import { PandaGen } from '../../src/pandagen'; 48 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = ++i"), 0, undefined); 69 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = --i"), 0, undefined); 90 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = +i"), 0, undefined); 110 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = -i"), 0, undefined); 130 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = !i"), 0, undefined); 154 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("let i = 5; let j = ~i"), 0, undefined);
|
D | new.test.ts | 38 import { PandaGen } from '../../src/pandagen'; 43 IRNode.pg = new PandaGen("", creatAstFromSnippet("new Object"), 0, undefined); 59 IRNode.pg = new PandaGen("", creatAstFromSnippet("new Object()"), 0, undefined); 76 IRNode.pg = new PandaGen("", creatAstFromSnippet("new Object(2)"), 0, undefined); 97 IRNode.pg = new PandaGen("", creatAstFromSnippet("let obj; new obj.ctor()"), 0, undefined); 120 IRNode.pg = new PandaGen("", creatAstFromSnippet("new Object(...args);"), 0, undefined);
|
/arkcompiler/ets_frontend/es2panda/ir/statements/ |
D | tryStatement.h | 22 class PandaGen; variable 61 void Compile(compiler::PandaGen *pg) const override; 66 void CompileTryCatch(compiler::PandaGen *pg) const; 67 void CompileTryFinally(compiler::PandaGen *pg) const; 68 void CompileTryCatchFinally(compiler::PandaGen *pg) const; 69 void CompileFinally(compiler::PandaGen *pg, compiler::TryContext *tryCtx,
|
/arkcompiler/ets_frontend/es2panda/compiler/base/ |
D | lreference.h | 39 class PandaGen; variable 43 LReference(const ir::AstNode *node, PandaGen *pg, bool isDeclaration, ReferenceKind refKind, 54 static LReference CreateLRef(PandaGen *pg, const ir::AstNode *node, bool isDeclaration); 58 PandaGen *pg_;
|
D | lexenv.h | 24 class PandaGen; variable 30 … static void Expand(PandaGen *pg, const ir::AstNode *node, const binder::ScopeFindResult &result); 37 …static void Expand(PandaGen *pg, const ir::AstNode *node, const binder::ScopeFindResult &result, b…
|
D | optionalChain.h | 23 class PandaGen; variable 28 explicit OptionalChain(PandaGen *pg, const ir::AstNode *node); 37 PandaGen *pg_ {};
|
/arkcompiler/ets_frontend/es2panda/ir/expressions/ |
D | memberExpression.h | 24 class PandaGen; variable 81 void Compile(compiler::PandaGen *pg) const override; 82 void Compile(compiler::PandaGen *pg, compiler::VReg objReg) const; 83 void CompileObject(compiler::PandaGen *pg, compiler::VReg dest) const; 84 compiler::Operand CompileKey(compiler::PandaGen *pg) const;
|
D | objectExpression.h | 24 class PandaGen; variable 82 void Compile(compiler::PandaGen *pg) const override; 90 …void EmitCreateObjectWithBuffer(compiler::PandaGen *pg, compiler::LiteralBuffer *buf, bool hasMeth… 91 void CompileStaticProperties(compiler::PandaGen *pg, util::BitSet *compiled) const; 92 …void CompileRemainingProperties(compiler::PandaGen *pg, const util::BitSet *compiled, compiler::VR…
|
/arkcompiler/ets_frontend/ts2panda/tests/statements/ |
D | variableDeclaration.test.ts | 43 import { PandaGen } from '../../src/pandagen'; 51 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 68 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 84 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 100 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 118 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 134 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 145 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 156 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 167 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); [all …]
|
D | functionDeclaration.test.ts | 42 import { PandaGen } from '../../src/pandagen'; 48 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 70 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 87 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 111 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 126 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 133 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 162 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined);
|
D | while.test.ts | 40 import { PandaGen } from '../../src/pandagen'; 62 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 63 (<PandaGen>(IRNode.pg)).updateIcSize(2); 91 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 92 (<PandaGen>(IRNode.pg)).updateIcSize(1); 125 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 158 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined);
|
/arkcompiler/ets_frontend/ts2panda/tests/ |
D | hoist.test.ts | 38 import { PandaGen } from '../src/pandagen'; 45 IRNode.pg = new PandaGen("foo", creatAstFromSnippet("var a = 1;"), 0, undefined); 62 IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`if (true) { 85 IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`function a() {};`), 0, undefined); 100 …IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`function a() {}; function a() {}`), 0, undefi… 116 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`var a = 1; function a() {}`), 0, undefined); 134 … IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`function a() {var a = 1;}`), 0, undefined); 154 …IRNode.pg = new PandaGen("foo", creatAstFromSnippet(`function a() {function b() {}};`), 0, undefin…
|
/arkcompiler/ets_frontend/ts2panda/src/ |
D | lexenv.ts | 33 import { PandaGen } from "./pandagen"; 64 abstract expand(pandaGen: PandaGen, compiler: Compiler): Array<IRNode>; 72 expand(pandaGen: PandaGen): Array<IRNode> { 80 private loadLocalVar(pandaGen: PandaGen): Array<IRNode> { 96 private loadLexEnvVar(pandaGen: PandaGen): Array<IRNode> { 121 expand(pandaGen: PandaGen): Array<IRNode> { 129 private storeLocalVar(pandaGen: PandaGen): Array<IRNode> { 154 private storeLexEnvVar(pandaGen: PandaGen): Array<IRNode> { 190 function checkConstAssignment(pg: PandaGen, v: Variable, expansion: IRNode[], node: ts.Node | NodeK…
|
/arkcompiler/ets_frontend/ts2panda/tests/watch_expression/ |
D | addWatch.test.ts | 22 import { PandaGen } from '../../src/pandagen'; 76 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 102 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 133 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 155 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 176 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 208 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 241 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 267 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); 299 IRNode.pg = new PandaGen("", creatAstFromSnippet(``), 0, undefined); [all …]
|