Skip to content

Commit

Permalink
Add support for Gradle assignment operator
Browse files Browse the repository at this point in the history
  • Loading branch information
cloudshiftchris committed Jun 11, 2024
1 parent 520706e commit 6a1a83a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,10 @@ internal class RedundantImportDetector(val enabled: Boolean) {
// Property delegation operators
"getValue",
"setValue",
"provideDelegate")
"provideDelegate",
// assign operator - Gradle compiler plugin https://blog.gradle.org/simpler-kotlin-dsl-property-assignment
"assign"
)

private val COMPONENT_OPERATOR_REGEX = Regex("component\\d+")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1451,6 +1451,7 @@ class FormatterTest {
|import com.example.timesAssign
|import com.example.unaryMinus
|import com.example.unaryPlus
|import org.gradle.kotlin.dsl.assign
|"""
.trimMargin())

Expand Down

0 comments on commit 6a1a83a

Please sign in to comment.