lua AsyncEmbeddedScript don't run hscript for now

This commit is contained in:
2024-04-21 18:39:19 -06:00
parent fbf95de14b
commit 6adaee8dd6
2 changed files with 8 additions and 2 deletions

View File

@@ -244,11 +244,13 @@ class AsyncEmbeddedScript2 {
}
runWithErrorChecking(() -> {
#if !lua
if (hscriptInstructions.exists(instructionPointer)) {
runHscriptInstruction(instructionPointer, skipping, continuation);
} else {
instructions[instructionPointer](this, skipping, continuation);
return;
}
#end
instructions[instructionPointer](this, skipping, continuation);
});
if (tryCallNextWithTailRecursion) {

View File

@@ -11,7 +11,9 @@ class DSLTestCase extends Test {
function testAsync() {
var script = new AsyncDSLScript();
script.run();
#if !lua
Assert.isFalse(script.ranHscriptInstruction);
#end
Assert.isTrue(script.wholeScriptDone);
}
@@ -21,8 +23,10 @@ class DSLTestCase extends Test {
script.run();
var script2 = new AsyncDSLScriptThatWillCache2();
script2.run();
#if !lua
Assert.isTrue(script.ranHscriptInstruction || script2.ranHscriptInstruction);
Assert.isFalse(script.ranHscriptInstruction && script2.ranHscriptInstruction);
#end
Assert.isTrue(script.wholeScriptDone);
Assert.isTrue(script2.wholeScriptDone);
}