Skip to content

Conversation

helje5
Copy link

@helje5 helje5 commented Jul 30, 2020

If an API method is designed to never return, it should be marked as returning Never. This way Swift will warn you if you add code after a call to such a method.

If an API method is designed to never return, it should be marked as returning `Never`. This way Swift will warn you if you add code after a call to such a method.
@swift-server-bot
Copy link

Can one of the admins verify this patch?

3 similar comments
@swift-server-bot
Copy link

Can one of the admins verify this patch?

@swift-server-bot
Copy link

Can one of the admins verify this patch?

@swift-server-bot
Copy link

Can one of the admins verify this patch?

@fabianfett
Copy link
Contributor

@swift-server-bot test this please

@helje5
Copy link
Author

helje5 commented Jul 30, 2020

Note: Other run style methods might need this treatment (if deemed appropriate).

Copy link
Contributor

@fabianfett fabianfett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@helje5
Copy link
Author

helje5 commented Jul 31, 2020

Note that this is API semver major. Which probably triggers the errors. I'll turn the PR into an Issue.

@tomerd
Copy link
Contributor

tomerd commented Jul 31, 2020

thanks @helje5 we are not at 1.0 yet, so this should be fine imo

@fabianfett wdyt?

@helje5
Copy link
Author

helje5 commented Jul 31, 2020

I've created #151 to track this.

@fabianfett
Copy link
Contributor

@tomerd I think this would be a great addition and something we should get in before 1.0

@tomerd tomerd added the kind/enhancement Improvements to existing feature. label Jul 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/enhancement Improvements to existing feature.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants