changeset 1731:842a0e0fd8c5

fix repeat stmt
author Franklin Schmidt <fschmidt@gmail.com>
date Fri, 02 Sep 2022 10:22:31 -0600
parents b1b1f9a14928
children 8a6e48371c66
files src/luan/impl/LuanParser.java
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
diff -r b1b1f9a14928 -r 842a0e0fd8c5 src/luan/impl/LuanParser.java
--- a/src/luan/impl/LuanParser.java	Thu Sep 01 13:35:52 2022 -0600
+++ b/src/luan/impl/LuanParser.java	Fri Sep 02 10:22:31 2022 -0600
@@ -641,12 +641,12 @@
 		stmt.add( "boolean "+repeatVar+";  " );
 		stmt.add( "do {  " );
 		stmt.addAll( loop );
-		stmt.add( repeatVar+" = " );
+		stmt.add( repeatVar+" = Luan.checkBoolean(" );
 		stmt.addAll( cnd );
-		stmt.add( ";  " );
-		stmt.add( "} while( !Luan.checkBoolean(" );
+		stmt.add( ");  " );
+		stmt.add( "} while( !" );
 		stmt.add( repeatVar );
-		stmt.add( ") );  " );
+		stmt.add( " );  " );
 		return parser.success( stmt );
 	}