-
Notifications
You must be signed in to change notification settings - Fork 503
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
UnusedImport false positive with import kotlinx.android.synthetic as #286
Comments
Can you please provide a complete example? $ cat A.kts
import kotlinx.android.synthetic.main.fragment_searchresultobjects.recyclerview as recyclerView
recyclerView()
$ ktlint --debug A.kts
...
[DEBUG] 772ms / 1 file(s) / 0 error(s)
$ ktlint --version
0.28.0 Thank you. |
@shyiko, I can provide sanitized project for Android Studio which reproduce the behavior. There is the one fragment (ObjectsFragment) with disabled ktlint rule. It faild when rules will be enabled. |
Thank you very much! |
When you use import as for an import alias, ktlint detects a lint error: Unused import
Sample:
import kotlinx.android.synthetic.main.fragment_searchresultobjects.recyclerview as recyclerView
The text was updated successfully, but these errors were encountered: