Irmen de Jong

Results 107 comments of Irmen de Jong

At least all code generator backends now are no longer dependent on the "compiler Ast" but instead use that simpler "code Ast" instead. I'm finalizing this on the "codegen-on-new-ast" branch....

This has been an interesting collection of observations, but they're no longer relevant to the current state of how the compiler works. At least not for the "public" version of...

Capturing hasn't received much attention at all compared to other functions of the library, unfortunately, and I'm not using it myself either. I'm glad you found a solution. I'll investigate...

no idea the author of said PR just closed it without merging it it seems. 🤷‍♂️ this project was last updated in 2017 so i think it's abandoned, tbh

Yes. try ``Unpickler.registerConstructor(...)`` However you may find that you need to add a constructor for all numpy types that might be pickled into your ".sav" file. It could be easier...

Try to use the source code to figure out why you still get these errors. For example, here are a couple of unit tests that utilize the custom class constructor...

With -target virtual, it also crashes, but with a different error Exception in thread "main" java.lang.IllegalArgumentException: node prog8.code.ast.PtFunctionCall@ccd1bc3 name is not scoped: call at prog8.codegen.intermediate.IRCodeGen.verifyNameScoping$verifyPtNode(IRCodeGen.kt:65) at prog8.codegen.intermediate.IRCodeGen.verifyNameScoping$verifyPtNode(IRCodeGen.kt:79) at prog8.codegen.intermediate.IRCodeGen.verifyNameScoping$verifyPtNode(IRCodeGen.kt:79) at...

Minimal reproduction: ``` main { sub start() { void = call($2000) } } ``` related compiler crash: ``` main { sub start() { void = 123 } } ```

interesting, a register order problem. I'll have a look when I get back from my coding pause. You may be able to work around it by assigning one or both...