ios - Cannot specialize non-generic type 'Set' -


this nsmanagedobject:

@objc(order) class order: nsmanagedobject {      @nsmanaged var orderitems: set<orderitem> //error: cannot specialize non-generic type 'set' } 

anyone know why doesnt work?

orderitem file created , works following declaration:

@nsmanaged var orderitem: orderitem 

just reference if should come question in future nasty bug, since discussion went on in comments.

yes, default set type in swift generic, in case custom non-generic set class shadowing class defined language's standard library.

better choose different names classes, avoid name clashes. if needed, can use qualified name of classes refer class want.

standard language classes available under swift. namespace, while other classes can use name of module followed dot , name of class (e.g. foundation.nsstring).


Comments

Popular posts from this blog

AbotX : How do you create a parallel crawler that stays on and can be added to at run time from new requests -

testing - Detect whether test has failed within fixture -

android - Create single AAR file from multiple modules using Gradle -