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

String Enum v2.4.1 #17057

Closed
acopalipsis opened this issue Jul 10, 2017 · 1 comment
Closed

String Enum v2.4.1 #17057

acopalipsis opened this issue Jul 10, 2017 · 1 comment
Labels
Working as Intended The behavior described is the intended behavior; this is not a bug

Comments

@acopalipsis
Copy link

acopalipsis commented Jul 10, 2017

enum Enumeration {
    A = "value",
    B // Enum member must have initializer.
}

It should be or it's a bug?

@ikatyang
Copy link
Contributor

This is Working as Intended, see #15486 for more detail.

Enum members with string literal values must always specify an initializer, but enum members with numeric literal values may omit the initializer provided it is the first member or the preceding member has a numeric value.

@RyanCavanaugh RyanCavanaugh added the Working as Intended The behavior described is the intended behavior; this is not a bug label Jul 10, 2017
@microsoft microsoft locked and limited conversation to collaborators Jun 14, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Working as Intended The behavior described is the intended behavior; this is not a bug
Projects
None yet
Development

No branches or pull requests

3 participants