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

Inline case statements with single block body #252

Merged
merged 3 commits into from
Mar 27, 2020

Conversation

dansanduleac
Copy link
Contributor

Before this PR

Case statements with a block body get unnecessarily put onto the next line, causing checkstyle to complain.

Sometimes it's not possible to avoid this pattern, if you are defining variables inside the case statement.

After this PR

==COMMIT_MSG==
Case statements with a body consisting of a single block now inline their block.
==COMMIT_MSG==

Possible downsides?

@changelog-app
Copy link

changelog-app bot commented Mar 27, 2020

Generate changelog in changelog/@unreleased

Type

  • Feature
  • Improvement
  • Fix
  • Break
  • Deprecation
  • Manual task
  • Migration

Description

Case statements with a body consisting of a single block now inline their block.

Check the box to generate changelog(s)

  • Generate changelog entry

@policy-bot policy-bot bot requested a review from iamdanfox March 27, 2020 11:05
@dansanduleac
Copy link
Contributor Author

pong

@dansanduleac dansanduleac merged commit 921b635 into develop Mar 27, 2020
@dansanduleac dansanduleac deleted the ds/case-statements-block branch March 27, 2020 17:24
@svc-autorelease
Copy link
Collaborator

Released 0.3.27

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

Successfully merging this pull request may close these issues.

3 participants