blueloveTH 2 rokov pred
rodič
commit
438857a1f5
3 zmenil súbory, kde vykonal 3 pridanie a 3 odobranie
  1. 1 1
      README.md
  2. 1 1
      docs/index.md
  3. 1 1
      src/vm.cpp

+ 1 - 1
README.md

@@ -20,7 +20,7 @@
 
 **English |** [**简体中文**](README_zh.md)
 
-pkpy is a lightweight(~14K LOC) Python interpreter for game scripting, built on C++17 with STL.
+pkpy is a lightweight(~15K LOC) Python interpreter for game scripting, built on C++17 with STL.
 
 It aims to be an alternative to lua for game scripting, with elegant syntax, powerful features and competitive performance.
 pkpy is extremely easy to embed via a single header file `pocketpy.h`, without external dependencies.

+ 1 - 1
docs/index.md

@@ -5,7 +5,7 @@ label: Welcome
 
 # Welcome to pocketpy
 
-pkpy is a lightweight(~14K LOC) Python interpreter for game scripting, built on C++17 with STL.
+pkpy is a lightweight(~15K LOC) Python interpreter for game scripting, built on C++17 with STL.
 
 It aims to be an alternative to lua for game scripting, with elegant syntax, powerful features and competitive performance.
 pkpy is extremely easy to embed via a single header file `pocketpy.h`, without external dependencies.

+ 1 - 1
src/vm.cpp

@@ -609,7 +609,7 @@ Str VM::disassemble(CodeObject_ co){
 
     std::vector<int> jumpTargets;
     for(auto byte : co->codes){
-        if(byte.op == OP_JUMP_ABSOLUTE || byte.op == OP_POP_JUMP_IF_FALSE || byte.op == OP_SHORTCUT_IF_FALSE_OR_POP){
+        if(byte.op == OP_JUMP_ABSOLUTE || byte.op == OP_POP_JUMP_IF_FALSE || byte.op == OP_SHORTCUT_IF_FALSE_OR_POP || byte.op == OP_FOR_ITER){
             jumpTargets.push_back(byte.arg);
         }
         if(byte.op == OP_GOTO){