diff --git a/test262/config.py b/test262/config.py index 3e4872c28aeb360754f10379699028e8ce9a60f6..e04e869ae8a80d06a7ceda97b1a3b8b89988e744 100755 --- a/test262/config.py +++ b/test262/config.py @@ -34,11 +34,6 @@ ICUI_DIR = f"{CODE_ROOT}/out/hi3516dv300/clang_x64/global/i18n_standard" LLVM_DIR = f"{CODE_ROOT}/prebuilts/clang/ohos/linux-x86_64/llvm/lib/" ARK_JS_RUNTIME_DIR = f"{CODE_ROOT}/out/hi3516dv300/clang_x64/ark/ark_js_runtime" -# " mode_type": { -# "1": "only default", -# "2": "only strict mode", -# "3": "both default and strict mode" -# } DEFAULT_MODE = 2 TEST_ES5_DIR = os.path.join(DATA_DIR, "test_es51") diff --git a/testTs/config.py b/testTs/config.py index c051991bf01c6d6b64580fe8353fe0c2b727f82a..7a29a4b70f2b76cc2c3cf2b7b268018c3970809a 100644 --- a/testTs/config.py +++ b/testTs/config.py @@ -34,11 +34,9 @@ IMPORT_FILE_PATH = os.path.join("testTs", "import_tests.json") CUR_FILE_DIR = os.path.dirname(__file__) CODE_ROOT = os.path.abspath(os.path.join(CUR_FILE_DIR, "../../..")) ARK_DIR = f"{CODE_ROOT}/out/hi3516dv300/clang_x64/ark/ark" -# ARK_DIR = f"{CODE_ROOT}/out/ohos-arm-release/clang_x64/obj/ark" WORK_PATH = f'{CODE_ROOT}/ark/ts2abc' DEFAULT_ARK_FRONTEND_TOOL = os.path.join(ARK_DIR, "build", "src", "index.js") -# DEFAULT_ARK_FRONTEND_TOOL = os.path.join(ARK_DIR, "ts2abc", "ts2panda", "build", "src", "index.js") TEST_PATH = os.sep.join([".", "testTs", "test"]) OUT_PATH = os.sep.join([".", "out", "testTs"]) @@ -49,4 +47,4 @@ ABC_EXT = ".abc" IMPORT_TEST = "" with open(IMPORT_FILE_PATH,'r') as f: content = f.read() - IMPORT_TEST = json.loads(content) \ No newline at end of file + IMPORT_TEST = json.loads(content) diff --git a/ts2panda/src/compilerUtils.ts b/ts2panda/src/compilerUtils.ts index 2480032b1d3459b1bdb2c6e312d5e658a4f77a43..42082fb7c2da751d22ea8b530ae884ee3de08ae3 100644 --- a/ts2panda/src/compilerUtils.ts +++ b/ts2panda/src/compilerUtils.ts @@ -221,7 +221,6 @@ function emitRestElement(restElement: ts.BindingName | ts.Expression, iterator: ); // get value from iter and store it to arrayObj - // getIterValue(iterRecord, iterValue, pandaGen, restElement); iterator.iteratorValue(iterResult); pandaGen.storeObjProperty(restElement, arrayObj, index); @@ -339,7 +338,6 @@ function compileObjectDestructuring(obj: ts.ObjectBindingOrAssignmentPattern, pa if (ts.isComputedPropertyName(key)) { compiler.compileExpression(key.expression); } else { - // compiler.compileExpression(key); if (ts.isIdentifier(key)) { let keyName = jshelpers.getTextOfIdentifierOrLiteral(key); pandaGen.loadAccumulatorString(key, keyName); diff --git a/ts2panda/src/recorder.ts b/ts2panda/src/recorder.ts index d500a8d297a91f558ae4f0d3d0648804890485bd..61f5689708d8b3af9391ed165d823cddaa506cd7 100644 --- a/ts2panda/src/recorder.ts +++ b/ts2panda/src/recorder.ts @@ -260,7 +260,6 @@ export class Recorder { let parent = this.getDeclarationNodeOfId(id); if (parent) { - // console.log(id.getText()); let declKind = astutils.getVarDeclarationKind(parent); // collect declaration information to corresponding scope diff --git a/ts2panda/tests/expression/delete.test.ts b/ts2panda/tests/expression/delete.test.ts index c6f318823b87bdcea5676195d3260b474a127a7b..9b180f1030747abc9f43a8e396cf1db0eac29081 100644 --- a/ts2panda/tests/expression/delete.test.ts +++ b/ts2panda/tests/expression/delete.test.ts @@ -26,7 +26,6 @@ import { LdaDyn, LdaiDyn, LdaStr, - ResultType, StaDyn, VReg } from "../../src/irnodes"; @@ -40,9 +39,6 @@ describe("deleteExpressionTest", function () { let propReg = new VReg(); let expected = [ - // let arr = [1, 2]; - // ... - // delete arr[1]; new EcmaStlettoglobalrecord('arr'), new EcmaTryldglobalbyname('arr'), new StaDyn(objReg),