Skip to content
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 intrinsics: change array_get from intrinsic_constructor to ins… #2776

Conversation

michaellilltokiwa
Copy link
Member

…trinsic

this fixes "Used abstract feature.." in javabase test:

  # NYI does not work yet: error 1: Used abstract feature 'String.utf8' is not implemented by 'String'
  # say (fuzion.java.array_to_java_object ["1","2","3"])

but now a new error:
java.lang.ClassCastException: class fzC_Const_String cannot be cast to class fzC_String (fzC_Const_String and fzC_String are in unnamed module of loader dev.flang.be.jvm.Runner @658c5a19)

@fridis
Copy link
Member

fridis commented Mar 21, 2024

java.lang.ClassCastException: class fzC_Const_String cannot be cast to class fzC_String

This should probably cast to fzI_String, fzC_String should only be used if the JVM backend is sure that there are no instantiated child features of fzC_String. So the code that decides if the need an interface or only a class depending on the children does not work as expected here.

@michaellilltokiwa michaellilltokiwa merged commit d2517bb into tokiwa-software:main Mar 25, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants