Przeglądaj źródła

Lua: do not clamp Std.int

Justin Donaldson 9 lat temu
rodzic
commit
c3508eb5f3
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      std/lua/_std/Std.hx

+ 1 - 1
std/lua/_std/Std.hx

@@ -38,7 +38,7 @@ import lua.Boot;
 	}
 
 	public static inline function int( x : Float ) : Int {
-		return lua.Boot.i32(x > 0 ? Math.floor(x) : Math.ceil(x));
+		return x > 0 ? Math.floor(x) : Math.ceil(x);
 	}
 
 	public static function parseInt( x : String ) : Null<Int> {