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

Lint for fallthrough in switch #14886

Merged
4 commits merged into from
Apr 18, 2017
Merged

Lint for fallthrough in switch #14886

4 commits merged into from
Apr 18, 2017

Conversation

ghost
Copy link

@ghost ghost commented Mar 27, 2017

Would be nice to use the compiler option for this, but that must wait on #11051.
Added issue #14885. Other missing breaks that seemed more obviously mistakes were added.

@@ -3623,7 +3625,8 @@ namespace ts {
// Private/protected properties/methods are not visible
return false;
}
// Public properties/methods are visible if its parents are visible, so const it fall into next case statement
// Public properties/methods are visible if its parents are visible, so
Copy link
Member

Choose a reason for hiding this comment

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

Comment got truncated

Copy link
Author

Choose a reason for hiding this comment

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

"falls through" needs to be on its own line for tslint to see it. So the continuation of this comment is on the next line. Added a colon to clarify.

@ghost ghost merged commit 60fe5a8 into master Apr 18, 2017
@ghost ghost deleted the fallthrough branch April 18, 2017 16:58
@microsoft microsoft locked and limited conversation to collaborators Jun 21, 2018
This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants