0

在我的空闲状态下,我尝试过-

    enum ButtonClicks { Monday, Tuesday, Wednesday, Thursday, Friday } ;
    typedef  enum  ButtonClicks { Monday, Tuesday, Wednesday, Thursday, Friday};

我收到 - MIDL2025 [msg] 语法错误 [context]:期望“;”附近有一个标识符
MIDL2025 [msg] 语法错误 [context]:需要关键字“interface”或...

4

2 回答 2

1

问题是枚举包含在 RuntimeClass 中。将它移到 RuntimeClass 之外编译 OK

于 2018-10-11T15:42:47.827 回答
0
enum ButtonClicks { Monday, Tuesday, Wednesday, Thursday, Friday}; 
typedef  enum   { Monday, Tuesday, Wednesday, Thursday, Friday} ButtonClicks;

最上面的应该自己工作,如果你想通过 typedef 来做,试试下面的

于 2018-10-09T21:08:42.677 回答