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

strings do not cast to int correctly in compiletime with -lua option #919

Open
rhazarian opened this issue Jan 8, 2020 · 0 comments
Open

Comments

@rhazarian
Copy link

The following example does not work.

package Test

import HashMap

let map = compiletime(new HashMap<string, string>())

@compiletime function initialize()
    map.put("hello", "world")

Error in File Hashtable.wurst line 11:
You encountered a bug in the interpreter: java.lang.Error: The native expects different parameter 2!
Expected: ILconstInt Actual: "hello"
at C:\Users\Rhaza\OneDrive\PC-3\Documents\SotFRP_build\dependencies\WurstStdlib2\wurst_handles\Hashtable.wurst line 11
Error in File Test.wurst line 7:
... when calling initialize() in Test.wurst:7
Error in File Test.wurst line 8:
... when calling HashMap_put(HashMap402_86, "hello", "world") in Test.wurst:8
Error in File HashMap.wurst line 18:
... when calling HashMap_has(HashMap402_86, "hello") in HashMap.wurst:18
Error in File HashMap.wurst line 14:
... when calling Table_hasInt(HashMap402_86, "hello") in HashMap.wurst:14
Error in File Table.wurst line 11:
... when calling hashtable_hasInt(ht35, 86, "hello") in Table.wurst:11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants