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

BfMain, method: m114 signature: ()V) Incompatible type for getting or setting field #1

Open
fraya opened this issue Mar 3, 2023 · 0 comments
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@fraya
Copy link
Owner

fraya commented Mar 3, 2023

When transpile the file mandelbrot.b with an optimization level of 0 or 1 (no optimization or remove comments) an Error happens.

$ fan fes2bf -O 0 -c res/mandelbrot.b
java.lang.VerifyError: (class: fan/bf4523911069070557234_0/BfMain, method: m114 signature: ()V) Incompatible type for getting or setting field
        at java.base/java.lang.Class.getDeclaredFields0(Native Method)
        at java.base/java.lang.Class.privateGetDeclaredFields(Class.java:3061)
        at java.base/java.lang.Class.getDeclaredFields(Class.java:2248)
        at fan.sys.ClassType.finishSlots(ClassType.java:591)
        at fan.sys.ClassType.finish(ClassType.java:553)
        at fan.sys.Method$MethodFunc.isStatic(Method.java:489)
        at fan.sys.Method$MethodFunc.callList(Method.java:205)
        at fan.sys.Type.make(Type.java:246)
        at fan.sys.ClassType.make(ClassType.java:110)
        at fan.sys.Type.make(Type.java:236)
        at fan.fes2bf.Main.run(Main.fan:69)
        at fan.util.AbstractMain.main(AbstractMain.fan:373)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at fan.sys.Method.invoke(Method.java:573)
        at fan.sys.Method$MethodFunc.callOn(Method.java:244)
        at fan.sys.Method.callOn(Method.java:139)
        at fanx.tools.Fan.callMain(Fan.java:185)
        at fanx.tools.Fan.executeType(Fan.java:147)
        at fanx.tools.Fan.execute(Fan.java:41)
        at fanx.tools.Fan.run(Fan.java:308)
        at fanx.tools.Fan.main(Fan.java:346)
[18:22:43 03-Mar-23] [err] [fes2bf] Unexpected error
  sys::Err: Method not mapped to java.lang.reflect correctly bf4523911069070557234_0::BfMain.make
    fan.sys.Method$MethodFunc.isStatic (Method.java:496)
    fan.sys.Method$MethodFunc.callList (Method.java:205)
    fan.sys.Type.make (Type.java:246)
    fan.sys.ClassType.make (ClassType.java:110)
    fan.sys.Type.make (Type.java:236)
    fes2bf::Main.run (Main.fan:69)
    util::AbstractMain.main (AbstractMain.fan:373)
    jdk.internal.reflect.NativeMethodAccessorImpl.invoke0 (NativeMethodAccessorImpl.java)
    jdk.internal.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
    jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    java.lang.reflect.Method.invoke (Method.java:566)
    fan.sys.Method.invoke (Method.java:573)
    fan.sys.Method$MethodFunc.callOn (Method.java:244)
    fan.sys.Method.callOn (Method.java:139)
    fanx.tools.Fan.callMain (Fan.java:185)
    fanx.tools.Fan.executeType (Fan.java:147)
    fanx.tools.Fan.execute (Fan.java:41)
    fanx.tools.Fan.run (Fan.java:308)
    fanx.tools.Fan.main (Fan.java:346)
@fraya fraya added bug Something isn't working help wanted Extra attention is needed labels Mar 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant