Native Abstracted Class Missing member declarations

When compiling down to a native shared library, the compiled class is missing member declarations.

For example (rough psuedo code, not compilable)

// In commonMain
abstract class car {
  abstract fun drive()
  fun stop() {}
}
// In nativeMain
class subaru : car {
  fun drive() {}
}

In the above example the header file for symbols generated for this would look something like:

struct {
  struct {
     drive(subaru)
  } subaru,
  struct {
     drive(car)
     stop(car)
  } car
}

So the functions that should have been inherited are not available on the subaru class… And the functions on the car class are not functional with a subaru instance…

I can’t figure out why it’s not bringing it in. The abstraction works if both the abstract class and the child class are in commonMain, but not if abstract is in commonMain and child is in nativeMain.

Some help/guidance would be nice if someone knows how to fix this other than writing the entire class over and over in each language :frowning:

Updates to this thread can be found at the official bug report here: https://youtrack.jetbrains.com/issue/KT-45333