I was trying to set a class to be a persistent data source using @Model
annotation, and somehow this happened:
The code above is generated by the compiler and the error is located in it.
Here is my code:
import SwiftData
class Animal {
}
@Model
class Dog: Animal {
let breed: String
init(breed: String) {
self.breed = breed
}
}
However, when I declare the Dog class with no super class, it work as expected.
Any idea?