我在使用NSUInteger时遇到了一些麻烦,我尝试了各种各样的东西并用Google搜索,但没有找到答案?
我......我也试过......非原子的,保留的
@property (readwrite, assign) NSUInteger *anAmount;
@synthesize anAmount;
Run Code Online (Sandbox Code Playgroud)
错误:属性'anAmount'的类型与ivar'anAmount'的类型不匹配
此外,当我在dealloc中发布它时,我收到警告..
警告:无效的接收器类型'NSUInteger'
Bol*_*ock 10
*如果您不打算使用指针NSUInteger(如果是值类型,而不是指针类型),请删除它:
@property (readwrite, assign) NSUInteger anAmount;
Run Code Online (Sandbox Code Playgroud)
并且不要释放它.