Repository and commit for context: swift-cross-ui at d763c22
When compiling DatePickerExample (in the Examples folder) using GtkBackend, I got this linker error:
error: undefined reference to '$s3Gtk3BoxC11orientation7spacingAcA11OrientationO_Sitcfc'
Helpful as all linker errors are, I had to investigate myself. The "missing" symbol is Gtk.Box.init(orientation:spacing:), which is defined here and called here. The call site is a super.init call, which I had forgotten at the time isn't allowed to call a convenience init. If I manually inline the convenience initializer, changing the call site to:
super.init(gtk_box_new(GTK_ORIENTATION_HORIZONTAL, 0))
then it compiles and runs fine.
Why was this misuse of a convenience initializer undiagnosed? Or if it's expected to work (which I don't think it is), why did it give a linker error? Is this a known issue?