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

Fix indent of "by" keyword #1322

Conversation

paul-dingemans
Copy link
Collaborator

Description

Original fix for #1210 (#1305) solved the runtime exception during formatting but also reformatted some delegate by constructs which are conflicting with the defaultIntelliJ formatting.

The runtime exception is still solved. I have added an explicit assert statement after the formatting stage which break units tests that would result in a negative indent level but otherwise still woud succeed. This should protect us against similar indent problem in the future.

The new formatting introduced in #1305 is reverted.

Checklist

  • tests are added
  • CHANGELOG.md is updated

Original fix for pinterest#1210 solved the runtime exception during formatting but also
reformatted some delegate by constructs which are conflicting with the default
IntelliJ formatting.
romtsn and others added 3 commits January 21, 2022 11:28
…ate-super-type-fix

# Conflicts:
#	ktlint-ruleset-standard/src/test/kotlin/com/pinterest/ktlint/ruleset/standard/IndentationRuleTest.kt
@paul-dingemans paul-dingemans merged commit 637ef2c into pinterest:master Jan 23, 2022
@paul-dingemans paul-dingemans deleted the 1210-indent-delegate-super-type-fix branch February 5, 2022 11:06
@pvegh
Copy link

pvegh commented Feb 10, 2022

pls 4 minor release kthxbye

@romtsn
Copy link
Collaborator

romtsn commented Feb 10, 2022

kthxbye

why?

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

Successfully merging this pull request may close these issues.

3 participants