Skip to content

Commit d62373c

Browse files
authored
Merge pull request #28 from TheBlueMatt/main
Provide Better Diagnostics when a Java method called from Rust panics
2 parents 8bb926d + 6e4aca0 commit d62373c

File tree

5 files changed

+156
-156
lines changed

5 files changed

+156
-156
lines changed

java_strings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -857,7 +857,7 @@ def native_c_map_trait(self, struct_name, field_vars, flattened_field_vars, fiel
857857

858858
out_c += "\tif ((*env)->ExceptionCheck(env)) {\n"
859859
out_c += "\t\t(*env)->ExceptionDescribe(env);\n"
860-
out_c += "\t\t(*env)->FatalError(env, \"A Java interface method called from rust threw an exception.\");\n"
860+
out_c += "\t\t(*env)->FatalError(env, \"A call to " + fn_line.fn_name + " in " + struct_name + " from rust threw an exception.\");\n"
861861
out_c += "\t}\n"
862862

863863
if fn_line.ret_ty_info.arg_conv is not None:

src/main/java/org/ldk/impl/bindings.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public VecOrSliceDef(long dataptr, long datalen, long stride) {
4848
static native String get_lib_version_string();
4949

5050
public static String get_ldk_java_bindings_version() {
51-
return "v0.0.98.4";
51+
return "v0.0.98.5";
5252
}
5353
public static native String get_ldk_c_bindings_version();
5454
public static native String get_ldk_version();

0 commit comments

Comments
 (0)