Commit Graph

6 Commits

Author SHA1 Message Date
Mikhail Pyltsin
43ad0b4707 [java-inspection] IDEA-281947 Useless pattern guard not suggested for removal
- remove guard if it is always true

GitOrigin-RevId: 168a103e93a42c9a82657abffcbd7626047cab3d
2023-12-14 19:49:09 +00:00
Tagir Valeev
dbccf5f59b [java-inspections] Delete switch branch when guard is false
Part of IDEA-326939 Support multi-pattern switch labels that define no variables

GitOrigin-RevId: 6d089c7e9f705a28f29376f1208ed39d4c8aa881
2023-08-18 08:18:08 +00:00
Tagir Valeev
7e1064ea3c [java-intentions] More preview tests; minor fixes
GitOrigin-RevId: 22a46c15d8900d8a31514846755a013f6a67ad42
2022-07-29 17:55:13 +00:00
Tagir Valeev
d70063b9f2 [java-dfa] Avoid marking annotation method results as non-null
While annotation implementations created by reflection never return nulls, it's possible to create a custom annotation interface implementation and nothing stops from returning null in this case. This leads to false-positives.
Fixes IDEA-269686 Wrong inspection message for nullable return value of annotation
Rollback IDEA-151174 Annotation method return values are non-nullable

GitOrigin-RevId: 88301bd8f5fb69e1e78efc23ecc1416c7c441473
2021-05-21 11:42:30 +00:00
Ilyas Selimov
3642a47796 DFA - moved the tests associated with "Simplify" quick-fix to a dedicated place
GitOrigin-RevId: 8bd67d61335fc77c2f8e115bfda45ade06041283
2021-05-18 10:27:41 +00:00
Ilyas Selimov
d82ff9650f DFA - excluded boolean fix suggestion in conditional expressions which contain null expression types to prevent compilation error
GitOrigin-RevId: b0b956ad677ce1ecdc80070e25877aef8dc65100
2021-05-14 17:22:38 +00:00