Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

关于枚举(Enumerated Types)的想法 #78

Open
zhangfurun opened this issue Aug 31, 2018 · 0 comments
Open

关于枚举(Enumerated Types)的想法 #78

zhangfurun opened this issue Aug 31, 2018 · 0 comments

Comments

@zhangfurun
Copy link

枚举的想法,关于两种枚举的写法
个人建议,还是采用文中提到的旧方法
建议理由:
1.旧方法简单快捷,而且在不特定设置快捷代码块的情况下,系统自带,一般情况,敲出来enum就会提示
typedef enum : NSUInteger {
<#MyEnumValueA#>,
<#MyEnumValueB#>,
<#MyEnumValueC#>,
} <#MyEnum#>;

2.在OC与Swift混编的情况下,新的枚举不能使用,应为目前涉及到#define

在快捷和混编的情况下,我更倾向于枚举的旧写法

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant