-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
crash occurs if the base class is NSObject #25
Comments
Reproduced, thanks! When it was searching through the super classes it wasnt stopping at NSObject. #26 should fix it. Would you mind giving the |
Thank you, i confirmed that it works well. my real problem is below import Realm
import RealmSwift
class RealmUser: Object {
@objc dynamic var id: Int = 0
@objc dynamic var username: String = ""
@objc dynamic var email: String = ""
}
let realmInfo = try typeInfo(of: RealmUser.self)
let realmProperty = try realmInfo.property(named: "username")
print("name: \(realmProperty.name)")
print("type: \(realmProperty.type)")
can this problem be solved? i hope to be.. |
hmmmm im not to sure. Id have to set up a realm project. However I wouldn't use this project with Realm. Setting a property via reflection with this lib wont actually trigger realm to actually save it. Out of curiosity whats the use case? |
After read your comment, It seems to useless.. but if runtime library applied to unsupported type, I think it would be better to print error message instead of crash. and that use case just simple class inheritance.. sorry (T_T) |
how fix this problem? and is there any plan to support objective-c language?
The text was updated successfully, but these errors were encountered: