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

ScalafmtConfig: validate once in the decoder only #2105

Merged
merged 2 commits into from
Jul 20, 2020

Conversation

kitbellew
Copy link
Collaborator

There are multiple places where a configuration instance is created, and some of them are not really appropriate for validation, such as StyleMap where custom configuration copies are created based on comments in the code, or to support binPack.literalArgumentLists.

Therefore, let's just validate the initial configuration in the decoder and not the custom adjustments.

Fixes #2098.

There are multiple places where a configuration instance is created, and
some of them are not really appropriate for validation, such as StyleMap
where custom configuration copies are created based on comments in the
code, or to support binPack.literalArgumentLists.

Therefore, let's just validate the initial configuration in the decoder
and not the custom adjustments.
@kitbellew kitbellew requested a review from poslegm July 20, 2020 14:23
@kitbellew kitbellew merged commit 45e0bae into scalameta:master Jul 20, 2020
@kitbellew kitbellew deleted the 2098 branch July 20, 2020 15:55
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.

Error formatting file with scalafmt 2.6.3
2 participants