Hi!
I have a problem were I use a concept that looks similar to this:
type
Widgetable* = concept
proc draw(self: var Self)
I use it to feed a converter that converts it to an interface:
type
WidgetInterface* = object
proc draw(self: var Self)
converter toWidgetInterface*(w: Widgetable): WidgetInterface =
let
w_ptr = w.addr # <- use a pointer to work around compiler error
result.draw = proc() = w_ptr[].draw() This works fine, until I want to use it to compile a program with picosdk4nim, then it fails to match some (but not all!) Widgets to the concept. When compiling normally, without picosdk4nim the concepts match as expected.
Unfortunately I'm having a hard to time make a reduced example that shows that error, so I'd like to ask how one would go on to debug this kind of problem.