Hi all ๐ ,
I am working on adding some custom lint checks in my project.
I am referring to this new video -
https://www.youtube.com/watch?v=q5q-y3eZTSAโพ
by Tor Norbye.
I am stuck in checking top-level declaration.
How to distinguish between a user-defined class and an implicit class?
More details in thread. ๐งต
K 1
Abhimanyu
07/17/2024, 11:54 AM
In Kotlin, creating a file with top level variables or functions also have an implicit class.
Example,
Test.kt
Copy code
var x = 1
Will create a
TextKt
How to differentiate this and user defined class?
Abhimanyu
07/17/2024, 11:55 AM
Custom lint rule:
Enforce adding a prefix
My
(for example) to all top-level classes, variables and functions.