Jelajahi Sumber

Generate native Java exception message

杨博 (Yang Bo) 10 tahun lalu
induk
melakukan
8c3d6106f9
1 mengubah file dengan 2 tambahan dan 2 penghapusan
  1. 2 2
      std/java/internal/Exceptions.hx

+ 2 - 2
std/java/internal/Exceptions.hx

@@ -82,9 +82,9 @@ class Exceptions {
 		else if (Std.is(obj, String))
 			ret = new HaxeException(obj, obj, null);
  		else if (Std.is(obj, Throwable))
-			ret = new HaxeException(obj, null, obj);
+			ret = new HaxeException(obj, Std.string(obj), obj);
 		else
-			ret = new HaxeException(obj, null, null);
+			ret = new HaxeException(obj, Std.string(obj), null);
 		return ret;
 	}
 }