Address Misc Warnings (#2698)

* Address compiler warnings

* Typo
This commit is contained in:
Adlai Holler
2016-12-02 14:04:05 -08:00
committed by appleguy
parent 9706b85145
commit 1997073802
3 changed files with 5 additions and 3 deletions

View File

@@ -123,7 +123,8 @@
{ {
__weak __typeof__(self) weakSelf = self; __weak __typeof__(self) weakSelf = self;
ASDisplayNodeViewBlock collectionViewBlock = ^UIView *{ ASDisplayNodeViewBlock collectionViewBlock = ^UIView *{
__typeof__(self) strongSelf = weakSelf; // Variable will be unused if event logging is off.
__unused __typeof__(self) strongSelf = weakSelf;
return [[ASCollectionView alloc] _initWithFrame:frame collectionViewLayout:layout layoutFacilitator:layoutFacilitator eventLog:ASDisplayNodeGetEventLog(strongSelf)]; return [[ASCollectionView alloc] _initWithFrame:frame collectionViewLayout:layout layoutFacilitator:layoutFacilitator eventLog:ASDisplayNodeGetEventLog(strongSelf)];
}; };

View File

@@ -81,7 +81,8 @@
{ {
__weak __typeof__(self) weakSelf = self; __weak __typeof__(self) weakSelf = self;
ASDisplayNodeViewBlock tableViewBlock = ^UIView *{ ASDisplayNodeViewBlock tableViewBlock = ^UIView *{
__typeof__(self) strongSelf = weakSelf; // Variable will be unused if event logging is off.
__unused __typeof__(self) strongSelf = weakSelf;
return [[ASTableView alloc] _initWithFrame:frame style:style dataControllerClass:dataControllerClass eventLog:ASDisplayNodeGetEventLog(strongSelf)]; return [[ASTableView alloc] _initWithFrame:frame style:style dataControllerClass:dataControllerClass eventLog:ASDisplayNodeGetEventLog(strongSelf)];
}; };

View File

@@ -20,7 +20,7 @@ NS_ASSUME_NONNULL_BEGIN
@class ASRangeController; @class ASRangeController;
@interface ASCollectionView () @interface ASCollectionView ()
- (instancetype)_initWithFrame:(CGRect)frame collectionViewLayout:(UICollectionViewLayout *)layout layoutFacilitator:(nullable id<ASCollectionViewLayoutFacilitatorProtocol>)layoutFacilitator eventLog:(ASEventLog*)eventLog; - (instancetype)_initWithFrame:(CGRect)frame collectionViewLayout:(UICollectionViewLayout *)layout layoutFacilitator:(nullable id<ASCollectionViewLayoutFacilitatorProtocol>)layoutFacilitator eventLog:(nullable ASEventLog *)eventLog;
@property (nonatomic, weak, readwrite) ASCollectionNode *collectionNode; @property (nonatomic, weak, readwrite) ASCollectionNode *collectionNode;
@property (nonatomic, strong, readonly) ASDataController *dataController; @property (nonatomic, strong, readonly) ASDataController *dataController;