-
Notifications
You must be signed in to change notification settings - Fork 197
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
Nullability and Generics #107
Nullability and Generics #107
Conversation
@jvisenti for your perusal. |
|
||
@end | ||
// clang-format off |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#? Should this be clan-format on
?
|
||
/** | ||
* Calls [self debugStringIncludeImageAddresses:YES] | ||
* | ||
* @return The debug string, including pointer addresses of attached images. | ||
*/ | ||
- (NSString *)debugString; | ||
- (NSString *_Nonnull)debugString; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#? doesn't - (nonnull NSString *)debugString
work (here and elsewhere)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
D'oh, so that's how you do it. I stopped at the first one I successfully got to compile. Fixing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_Nonnull
and its ilk are for C functions (and therefore blocks as well).
@ZevEisenberg Looks good overall. You probably want to consider maintaining pre-Xcode 7 support via compatibility macros e.g. https://github.com/Raizlabs/RZImport/blob/master/Classes/RZCompatibility.h |
@jvisenti should be good to go now. I haven't tested in Swift. Would you mind checking it out in your Swift project and seeing if the edge cases with implicitly unwrapped optionals that you reported are handled correctly now? |
@ZevEisenberg Confirmed that this behaves as expected in a Swift app. |
…ity-and-generics Nullability and Generics
Closes #31