Skip to content

Commit

Permalink
ffi: add c-style char* strings as a supported return type
Browse files Browse the repository at this point in the history
  • Loading branch information
ScrelliCopter committed Sep 10, 2023
1 parent c04c562 commit f17bb12
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ class JnaNativeProvider : NativeFunctionProvider {
"float" -> function.invokeFloat(values)
"double" -> function.invokeDouble(values)
"void" -> function.invokeVoid(values)
"char*" -> function.invokeString(values, false)
else -> throw RuntimeException("Unsupported ffi return type: $type")
}
}

0 comments on commit f17bb12

Please sign in to comment.