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
Java codegen generates duplicate methods for records depending on parameter usage order #2367
Comments
To complete the details needed to work on this ticket, typeclass derivation has no impact on the issue. For readability and to make all cases compile, the following represents a minimal DAML source file that reproduces the issue (as tested against 997212c):
As already mentioned, cases 6-8 do not cause any issue. Cases 1-5 produce duplicate |
Hi,
We have discovered a few cases where a DAML record type with one or more type parameters results in the Java codegen creating classes that have duplicate functions defined in them. It appears the Java compiler complains that the functions are duplicate due to type erasure (?)
Interestingly, changing the order of usage of the type parameters within the data type to reflect the order of declaration results in correct Java code generation
The text was updated successfully, but these errors were encountered: