'Existing ivar 'delegate' for unsafe_unretained property 'delegate' must be __unsafe_unretained

前端 未结 6 814
谎友^
谎友^ 2020-12-25 11:30

I\'m getting the error above, but unsure how to go about fixing it. This is my code:

.h:

#import 

@protocol ColorLineDelegate &         


        
6条回答
  •  旧时难觅i
    2020-12-25 11:54

    Perhaps a bit late but to be "ARC compliant", you simply have to replace

    @property (nonatomic, assign) id  delegate;
    

    by

    @property (nonatomic, strong) id  delegate;
    

    Bye.

提交回复
热议问题