-
Notifications
You must be signed in to change notification settings - Fork 6
Record types don't exist #11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Also, is it possible to emit JSON? I want to use this project to create 'bindings' for another language I'm working on to interface with Java, and this would really be useful |
See #10 for workaround that just skips records. I haven't looked too closely to it, but according to PR author it is a limitation of JavaParser. A better workaround that actually emits records might be possible, but I'm unlikely to work on it anytime soon. JSON output is already available, but the format is neither documented or stable (see https://github.com/bensku/java-ts-bind/blob/master/src/main/java/io/github/bensku/tsbind/cli/Args.java for command-line option). I would not recommend using this for your own language as-is, but maybe this could serve as a starting point. |
Hm fair enough, thanks! I've actually decided to use reflection to map out Java arguments and types, parameter names are included in bytecode if you specify it in |
For record, I built this to avoid loading classes (potentially with side effects in static initializers) and to convert Javadoc to JSDoc. If you don't need the latter, it is probably much easier to parse bytecode or (as you do), use reflection. |
Heya, @bensku is there any plans to add support for record types?
The text was updated successfully, but these errors were encountered: