这是我的 Board 头文件:
#import "Game.h"
#import <Foundation/Foundation.h>
@interface Board : UIView
{
enum Piece;
}
- (void) setGame: (Game*) theGame; //<-- this is where the error is
typedef enum {X, O, NONE} Piece;
- (float)getSection;
@end
编译器说“期望一个类型”并在 (Game*) 下划线。这里有什么问题?
游戏.h:
#import <Foundation/Foundation.h>
#import "Board.h"
@interface Game : UIViewController
- (void)boardwasTapped:(int) row:(int) column;
@end