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

Allow single case on same line as what comes before #29

Closed
jppellet opened this issue Jul 27, 2011 · 2 comments
Closed

Allow single case on same line as what comes before #29

jppellet opened this issue Jul 27, 2011 · 2 comments

Comments

@jppellet
Copy link

Sorry, my title is especially vague and uninformative. Here's an example.

list.foreach { elem =>
  /* do something with elem */
}

list.foreach { case (key, value) => // (***)
  /* do something with elem */
}

It would be great if there was an option to keep my standalone case on line *** on the same line (currently it always wraps before "case"), to mimic the style for the non-tuple case, recommended by the Scala Style Guide. It would remove one useless level of indentation.

@godenji
Copy link
Collaborator

godenji commented Oct 28, 2017

@jppellet More than 6 years after the fact this issue can now be closed -- exciting, no?

Probably not, but thanks for raising the issue regardless, a nice improvement.

@godenji godenji closed this as completed Oct 28, 2017
@jppellet
Copy link
Author

That's cool! Thanks!

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

No branches or pull requests

3 participants