Skip to content

rubocop: require braces for Sorbet sig#10351

Merged
SeekingMeaning merged 1 commit intoHomebrew:masterfrom
SeekingMeaning:sig-braces
Jan 19, 2021
Merged

rubocop: require braces for Sorbet sig#10351
SeekingMeaning merged 1 commit intoHomebrew:masterfrom
SeekingMeaning:sig-braces

Conversation

@SeekingMeaning
Copy link
Copy Markdown
Contributor

@SeekingMeaning SeekingMeaning commented Jan 18, 2021

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?
  • Have you successfully run brew man locally and committed any changes?

I think this is more readable

(Should we have a vote of 👍 or 👎?)

@BrewTestBot
Copy link
Copy Markdown
Contributor

Review period will end on 2021-01-19 at 06:49:41 UTC.

@BrewTestBot BrewTestBot added the waiting for feedback Merging is blocked until sufficient time has passed for review label Jan 18, 2021
Copy link
Copy Markdown
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

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

I prefer this style, too, but I think as long as it's consistent one way or the other I don't have strong views. It seems this is the predominant style so far.

@SeekingMeaning SeekingMeaning marked this pull request as ready for review January 18, 2021 17:17
Copy link
Copy Markdown
Member

@Rylan12 Rylan12 left a comment

Choose a reason for hiding this comment

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

Just to add another voice:

I agree this makes sense. I definitely prefer the one-line signatures (when they're possible) which look much better with braces, so it makes sense to choose braces as The One Way.

The only thing I'd say is that it can sometimes be confusing to ruby beginners (at least, it was for me) what a block is and the fact that braces and do end are the same, so adding inconsistency on that front might be a concern. Probably not a major one, though, because most people who aren't already comfortable probably won't care much about that, so I'd say 👍 to this change.

@BrewTestBot
Copy link
Copy Markdown
Contributor

Review period ended.

@BrewTestBot BrewTestBot removed the waiting for feedback Merging is blocked until sufficient time has passed for review label Jan 19, 2021
@SeekingMeaning SeekingMeaning merged commit 50cd836 into Homebrew:master Jan 19, 2021
@BrewTestBot BrewTestBot added the outdated PR was locked due to age label Feb 19, 2021
@Homebrew Homebrew locked as resolved and limited conversation to collaborators Feb 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

outdated PR was locked due to age

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants