天天看點

IOS之提示Interface type cannot be statically allocated

1、問題

command  + R運作提示如下錯誤

Interface type cannot be statically allocated

2、解決辦法

是代碼寫錯了

User user = [[User alloc] init];

改成如下

User *user = [[User alloc] init];

繼續閱讀