projects
/
ldk-java
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9254f75
)
Handle uintptr_t slightly better in C conversion
author
Matt Corallo
<git@bluematt.me>
Mon, 25 Jan 2021 22:45:22 +0000
(17:45 -0500)
committer
Matt Corallo
<git@bluematt.me>
Mon, 25 Jan 2021 22:46:08 +0000
(17:46 -0500)
genbindings.py
patch
|
blob
|
history
diff --git
a/genbindings.py
b/genbindings.py
index f47cce3699d823ab2f972ba47e161f2d69791fef..32cad50a7480adebd50e43b81c12544a45b06c2c 100755
(executable)
--- a/
genbindings.py
+++ b/
genbindings.py
@@
-216,11
+216,12
@@
def java_c_types(fn_arg, ret_arr_len):
# TODO: uintptr_t is arch-dependent :(
mapped_type = consts.c_type_map['uint64_t']
java_ty = mapped_type[0]
- c_ty = "int64_t"
fn_ty_arg = "J"
if fn_arg.startswith("uint64_t"):
+ c_ty = "int64_t"
fn_arg = fn_arg[8:].strip()
else:
+ c_ty = "intptr_t"
fn_arg = fn_arg[9:].strip()
is_primitive = True
elif is_const and fn_arg.startswith("char *"):