-
Notifications
You must be signed in to change notification settings - Fork 506
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
--format of experimental:function-signature violates max-line-length #1527
Comments
Output below is not produced by
When running with the CLI you have to invoke command to enable the experimental rule:
This results in output:
Please check the configuration of the |
The point of this bug is not that the output looks ugly, the point is what ktlint auto-correction function does with Kotlin sources. This does not depend on the way you call ktlint.
I don't want to invoke ktlint from the command line, or download it manually. Are there any people except for its maintainers who do such things? But sure, let's waste some more time. Here is the output from my console.
|
Ok, the problem is that with each invocation of
and
I would have expected that neither of them were reported as it is an error which is autocorrected and such errors are not reported when running with For now, you can disable the entire rule or set following in the
|
… it fits on the same line Closes pinterest#1527
Expected Behavior
--format
withexperimental:function-signature
enabled does not change the code at all if whole function definition does not fit into line lengthexperimental:function-signature
does not report an error if a function expression is in multiple lines that cannot be safely joined--format
ofexperimental:function-signature
should not introduce new rule violations as it happens in the example belowObserved Behavior
Steps to Reproduce
Original file:
.editorconfig:
Run
ktlint --format
.File produced by ktlint (incorrect):
Your Environment
The text was updated successfully, but these errors were encountered: