Unable to create a static struct pointing to a function
I've been able to create non-buildable code with this snipet:
[CCode (has_target = false)]
public delegate void FooBar (Foo foo);
public struct Foo {
public FooBar bar;
}
static Foo myfoo = { foo_do_bar };
static void foo_do_bar (Foo foo) {
}
int main (string[] args) {
return 1;
}
it seems that the position of the foo_do_bar
prototype depends of the [CCode (has_target = false)]
.