Skip to content

JB-Dmitry/Mikes_IDEA_extensions

 
 

Repository files navigation

Mike's IDEA extensions

Some great inspections, quickfixes, tools. Well, only inspections at the moment.

Java inspections

  • BigDecimal instantiation can be replaced with constant by stokito
  • BigDecimal.compareTo(ZERO) can be replaced with signum() by stokito

UAST (Java + Kotlin) inspections

  • Atomic can be replaced with volatile
  • Allocation should be cached (Enum.values(), new Gson(), ...)

Kotlin inspections

  • Heavyweight property delegation
  • Declaration name is Java keyword
  • Inline function leaks anonymous declaration
  • Function won't be inlined; noinline callable references are a bit more expensive than noinline lambdas; function cannot be inlined if it is a receiver of an extension function

Android inspections

  • <include layout="?themeAttribute"> requires Marshmallow
  • <drawable android:tint and android:tintMode> require Lollipop
  • @TargetApi should be replaced with @RequiresApi
  • Use of reflective ObjectAnimator/PropertyValuesHolder

Tooltips/hints

  • Upcast to interface, e. g.
    putExtra(list as Serializable) (Java Only)
  • Method override from superclass, e. g.
    @Override from Runnable,
    override Runnable fun run()

Plugin page on JetBrains marketplace

About

IntelliJ IDEA: missing parts.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Kotlin 86.7%
  • Java 6.8%
  • HTML 6.5%