Browse Source

[hl] Fix hl.Int64 issue with -D hl_legacy32 (#12420)

* [hl] Fix hl.Int64 issue with -D hl_legacy32

* [CI] do not lock utest version
Yuxiao Mao 1 week ago
parent
commit
17d4a63378
3 changed files with 4 additions and 2 deletions
  1. 2 0
      std/hl/Api.hx
  2. 1 1
      std/hl/types/ArrayBytes.hx
  3. 1 1
      tests/RunCi.hx

+ 2 - 0
std/hl/Api.hx

@@ -59,7 +59,9 @@ extern class Api {
 	}
 	#end
 	#if (hl_ver >= version("1.16.0"))
+	#if !hl_legacy32
 	@:hlNative("?std", "sys_timestamp_ms") static function timestampMs():haxe.Int64;
+	#end
 	@:hlNative("?std", "sys_resolve_type") static function resolveTypeDyn( t : hl.Type, gt : hl.Type ) : Dynamic;
 	@:hlNative("?std", "sys_load_plugin") private static function _loadPlugin( file : hl.Bytes ) : Bool;
 	static inline function loadPlugin( file : String ) : Bool { return _loadPlugin(@:privateAccess file.bytes); }

+ 1 - 1
std/hl/types/ArrayBytes.hx

@@ -149,7 +149,7 @@ class BytesIterator<T> extends ArrayIterator<T> {
 		if (tid == Type.get(0))
 			(bytes : Bytes).sortI32(0, length, cast f);
 		else if( tid == Type.get((0:hl.I64)) ) {
-			#if (hl_ver >= version("1.16.0"))
+			#if (hl_ver >= version("1.16.0") && !hl_legacy32)
 			(bytes : Bytes).sortI64(0, length, cast f);
 			#else
 			throw "Array sort I64 requires -D hl-ver=1.16.0";

+ 1 - 1
tests/RunCi.hx

@@ -37,7 +37,7 @@ class RunCi {
 			infoMsg('test $test');
 			try {
 				changeDirectory(unitDir);
-				haxelibInstallGit("ncannasse", "utest", "dec118f248649b20abb6148d0e9960ef93556fda", "--always");
+				haxelibInstallGit("haxe-utest", "utest", "--always");
 
 				var args = switch (ci) {
 					case null: