You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following parametrized typealias should not fail lint checks:
typealiasMySupplier<T> = () ->T
Observed Behavior
Ktlint expects a space before the <
./ktlint MySupplier.kt --experimental
MySupplier.kt:1:21: Expected a single space (experimental:type-parameter-list-spacing)
Autoformatting will apply the space:
// after ./ktlint -F MySupplier.kt --experimentaltypealiasMySupplier <T> = () ->T
but running check on the above results (as expected) in another failure:
MySupplier.kt:1:21: Unexpected spacing before "<" (experimental:spacing-around-angle-brackets)
interestingly running format a second time on the formatted file results in a failure:
./ktlint -F MySupplier.kt --experimental
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.jetbrains.kotlin.com.intellij.util.ReflectionUtil (file:/[...]/ktlint) to field java.lang.Throwable.backtrace
WARNING: Please consider reporting this to the maintainers of org.jetbrains.kotlin.com.intellij.util.ReflectionUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
Steps to Reproduce
Described above.
Your Environment
Version of ktlint used: 0.45.1
Relevant parts of the .editorconfig settings: n/a
Name and version (or code for custom task) of integration used (Gradle plugin, Maven plugin, command line, custom Gradle task): used standalone CLI
Version of Gradle used (if applicable): n/a
Operating System and version: MacOS Big Sur
The text was updated successfully, but these errors were encountered:
Expected Behavior
The following parametrized typealias should not fail lint checks:
Observed Behavior
Ktlint expects a space before the
<
Autoformatting will apply the space:
but running check on the above results (as expected) in another failure:
interestingly running format a second time on the formatted file results in a failure:
Steps to Reproduce
Described above.
Your Environment
.editorconfig
settings: n/aThe text was updated successfully, but these errors were encountered: