opened
adamkobor
username_0
Hey there, I'm experiencing a weird bug with the `ExplicitItLambdaParameter` rule. I've enabled it in my config.yml, but it definitely doesn't trigger any rule violation.
 
## Expected Behavior
It should trigger a rule violation for multi-line lambdas with implicit `it` parameters.

## Observed Behavior
It doesn't trigger a rule violation in the cases described above.

## Steps to Reproduce
Write a multi-line lambda with an implicit `it` parameter, and run detekt:

```kotlin
listOf("a","b").forEach {
    doSomething()
    println(it)
}
```

## Your Environment
<!-- Include as many relevant details about the environment you experienced the bug in -->
* Version of detekt used: 1.14.2
* Version of Gradle used (if applicable): 6.7.1
* Operating System and version: MacOS Big Sur
ExplicitItLambdaParameter rule is not working
issue
created
cortinico
username_1
As described in the rule documentation: https://detekt.github.io/detekt/style.html#explicititlambdaparameter
your code is actually valid, as you're using an **implicit** `it` parameter. The rule flags **explicit** usages of the `it` parameter.
comment
created
adamkobor
username_0
OMG, what a rookie mistake (and also a misread) 😄 Thanks, I was concentrating only to the word "lambda" in the rule's name
comment
closed
adamkobor
username_0
issue
created
QuinnBast
username_2
Hello. Just stumbled across this. Is there a rule that forces lambda parameters to be defined?
comment
created
BraisGabin
username_3
Your request is interesting but it's not related with this issue. Could you open a new issue so we can talk about it?

(Github should allow to move one comment directly to a new issue)
comment