We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Does jsweet support reflection? Upto what extent? Following do not work
Argument of type 'StringConstructor' is not assignable to parameter of type
Array.newInstance(itemClas, 0).getClass()
The text was updated successfully, but these errors were encountered:
Hello @maheshkurmi
JSweet has minimal support for reflection. It depends on whether you use J4TS or not, but you can expect basic introspection to be available (get methods of a class, get class name, get method name .. you can find detailed implementations in JSweet adapter: https://github.com/cincheo/jsweet/blob/develop/transpiler/src/main/java/org/jsweet/transpiler/extension/Java2TypeScriptAdapter.java#L1271)
but AFAIR you cannot expect to create instances dynamically with newInstance.
Please also read: https://github.com/cincheo/jsweet/blob/master/doc/jsweet-language-specifications.md#allowed-java-objects
Sorry, something went wrong.
No branches or pull requests
Does jsweet support reflection? Upto what extent?
Following do not work
Argument of type 'StringConstructor' is not assignable to parameter of type
Array.newInstance(itemClas, 0).getClass()
throws errorThe text was updated successfully, but these errors were encountered: