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

[SR-15657] Unimplemented computed property in enum is misdiagnosed as stored property #57936

WowbaggersLiquidLunch opened this issue Dec 24, 2021 · 3 comments


Copy link

@WowbaggersLiquidLunch WowbaggersLiquidLunch commented Dec 24, 2021

Previous ID SR-15657
Radar None
Original Reporter @WowbaggersLiquidLunch
Type Bug
Status Closed
Resolution Done

macOS 12.2 Beta (21D5025f)
Swift trunk development snapshot 2021-12-06

Additional Detail from JIRA
Votes 0
Component/s Compiler
Labels Bug, DiagnosticsQoI
Assignee @LucianoPAlmeida
Priority Medium

md5: d62063964d822e91a03f84e8d7bf8d49

Issue Description:

2 errors are produced for the following code:

enum E {
    // error 1: computed property must have accessors specified
    // error 2: enums must not contain stored properties
    var foo: Int {}

Only the error 1 is correct. Error 2 is incorrect.

Copy link

@LucianoPAlmeida LucianoPAlmeida commented Dec 26, 2021

PR opened #40705

Copy link

@LucianoPAlmeida LucianoPAlmeida commented Jan 11, 2022

Fixed on main, @WowbaggersLiquidLunch can you please verify on next available snapshot and close? Thanks

Copy link
Collaborator Author

@WowbaggersLiquidLunch WowbaggersLiquidLunch commented Feb 7, 2022

I can confirm that this is resolved as of the 2020-02-03 trunk toolchain

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

2 participants