2 ms·
I remember, I was a macOS engineer when it came out. I think NSPredicate, even a serializable one, makes sense. What doesn't make any sense is arbitrary select
by arcticbull 5y ago
I remember, I was a macOS engineer when it came out.
I think NSPredicate, even a serializable one, makes sense. What doesn't make any sense is arbitrary selector invocation. Not just because it's a security risk, but also because it's a stringly-typed method name that isn't checked by the compiler. The name of the selector changing would just cause it to crash - without a compile-time check. A plist with a serialized selector that no longer exists would cause the app to crash. A plist with a malicious selector would cause the app to crash. And crashing seems like a best case outcome.