‘assert’ is a macro that may be disabled by compiler flag and cause compilation 
issue. You should just use abort() instead.

> Le 10 juin 2015 à 16:50, Sean McBride <[email protected]> a écrit :
> 
> On Wed, 10 Jun 2015 02:16:04 -0500, Kyle Sluder said:
> 
>> You should be able to use the NS_UNAVAILABLE macro in your @interface to
>> "delete" -init from your subclass, and thus suppress the warning.
> 
> Ah, brilliant.  Works for me, I just put in my .m:
> 
> - (instancetype)init NS_UNAVAILABLE
> {
>       assert(0);
> }
> 
> No changes to interface or .h.  Nice.
> 
> Cheers,
> 
> -- 
> ____________________________________________________________
> Sean McBride, B. Eng                 [email protected]
> Rogue Research                        www.rogue-research.com 
> Mac Software Developer              Montréal, Québec, Canada
> 
> 
> 
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Xcode-users mailing list      ([email protected])
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/xcode-users/mailing%40xenonium.com
> 
> This email sent to [email protected]


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/xcode-users/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to