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

False positive reported by ModifierOrder when using fun interfaces #3050

Closed
chao2zhang opened this issue Sep 5, 2020 · 0 comments · Fixed by #3051
Closed

False positive reported by ModifierOrder when using fun interfaces #3050

chao2zhang opened this issue Sep 5, 2020 · 0 comments · Fixed by #3051

Comments

@chao2zhang
Copy link
Member

Expected Behavior

A code snippet like the following is using the Kotlin SAM introduced in Kotlin 1.4

    internal fun interface LoadMoreCallback {
        fun loadMore()
    }

This should pass the detekt check

Observed Behavior

We got a ModifierOrder issue with the error message "Modifier order should be: fun internal".

Context

We have recently upgraded our codebase to use Kotlin 1.4, there is only one occurrence so we can suppress it to unblock us.

Your Environment

Version of detekt used: 1.12.0
Version of Gradle used (if applicable): 6.6.1
Operating System and version: macOS Catalina 10.15.6

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants