Commit Graph
293 Commits
Author SHA1 Message Date
peter e3c07073c5 honor array component type nullability in index expression dfa (IDEA-154874) 2016-04-19 14:00:31 +02:00
peter 1475442c3f IDEA-154811 Nullable inspection is incorrect with user-defined valueOf static method in Enum 2016-04-19 12:33:19 +02:00
peter 0a9d2963ae don't lose precision during constant comparison in dfa (IDEA-153532) 2016-03-24 11:54:45 +01:00
peter f871d33fc8 IDEA-151355 Wrong 'condition always false' after using decrement on object field 2016-02-10 12:39:20 +01:00
peter c1fdc02b1a Enum.valueOf and annotations methods are not-null (IDEA-151305, IDEA-151174) 2016-02-10 12:39:19 +01:00
peter b3c40ee773 dfa: highlight just method reference name on possible NPE warnings (IDEA-149904) 2016-01-20 16:47:53 +01:00
peter 1392e7705f dfa: don't shadow final variable reassignments with wide irrelevant warnings (IDEA-148984) 2016-01-19 18:15:31 +01:00
peter f012d6fe41 dfa: flush only ++ unary operator arguments (IDEA-150271) 2016-01-19 18:15:31 +01:00
peter 0ddd1243b9 honor vararg calls when inferring contracts (IDEA-148862) 2015-12-03 17:32:53 +01:00
peter 9d2abd7276 IDEA-148657 "if (false)" quickfix text is meaningless 2015-11-30 16:26:38 +01:00
peter ab6ec15175 IDEA-148477 Handle AssertJ assertions in the same way as JUnit assertions 2015-11-26 08:28:04 +01:00
peter 2aa8b8c099 Revert: perform arithmetic operations during dfa (part of IDEA-143315) (ea61e3e9e6) 2015-11-18 16:14:35 +01:00
peter ea61e3e9e6 perform arithmetic operations during dfa (part of IDEA-143315) 2015-11-17 17:19:44 +01:00
peter 66b5456707 IDEA-146131 @NotNull on parameters should only apply until reassignment 2015-11-17 17:19:43 +01:00
peter 27271e9979 dfa: IDEA-146950 "<" expr is always false but "<=" is not 2015-10-28 14:02:36 +01:00
peter 488ef11fd4 dfa: support (i)++ (IDEA-146805) 2015-10-26 16:20:47 +01:00
peter af07f88aef IDEA-146122 Wrong 'can produce NPE' after comparing with enum constant 2015-10-12 13:33:38 +02:00
peter 67bfef7b1d dfa: add a test for assignment with side effects inside method calls (IDEA-145401, IDEA-CR-5542) 2015-10-12 13:33:37 +02:00
peter f3c4a52ece dfa: don't suggest to assert/surround-with-if possible NPEs on volatile fields, suggest to extract a local variable instead (IDEA-145668) 2015-10-06 16:59:10 +02:00
peter f98d01be5e dfa: don't suggest to simplify boolean expressions with side effects (IDEA-145401) 2015-10-06 15:29:27 +02:00
peter 06c0f35c8f IDEA-146009 Good code is yellow: "Unboxing may produce NPE" inside forEach lambda 2015-10-06 15:24:36 +02:00
peter bf4a3805e0 dfa: store CCE state in visitor, not runner: the latter is reused which can result in multiple warning 2015-09-01 21:48:59 +02:00
peter 0bae70149a IDEA-143937 Bogus warning by 'Constant conditions & exceptions' inspection within lambda expressions, due to JSR 305 @TypeQualifierDefault annotation 2015-08-18 20:00:23 +02:00
peter 0c28099a15 IDEA-143014 Wrong 'can be null' warning when assignment is done inside if condition 2015-07-31 13:28:36 +02:00
peter 1b70adbfd4 IDEA-137195 Not annotated constant fields should be treated as Nullable or NotNull when static code analysis is able to prove Nullable/NotNull 2015-07-20 17:20:58 +02:00
peter b091be1813 dfa: test that assert throws AssertionError (IDEA-69727) 2015-07-10 22:33:29 +02:00
peter eeabb7e9d8 IDEA-82971 False inspection int == double 2015-07-10 22:33:29 +02:00
peter 1f354e0e3d dfa: don't report parenthesized condition (IDEA-27427) 2015-07-10 20:38:55 +02:00
peter da6bf872ab IDEA-66134 Inspection "Constant conditions & exceptions": ignore boolean named constants 2015-07-10 20:38:55 +02:00
peter 99f343707f dfa: inspect enum constant methods (IDEA-142299) 2015-07-10 20:38:54 +02:00
peter 1155a92a9e dfa: suppress constant condition checking for expression-internal assignments (IDEA-31697) 2015-07-10 20:38:53 +02:00
peter b4a9a53ec7 dfa: report constant xor conditions only for the last operator in polyadic (IDEA-141853) 2015-06-24 18:37:44 +02:00
peter 69081779fe dfa, Optional.ofNullable: suggest improvements only if in all states the arg was null or non-null (IDEA-141843) 2015-06-24 16:47:22 +02:00
peter 02fc02798f dfa: handle in a special way only getX() != null comparisons (IDEA-141823) 2015-06-24 14:29:34 +02:00
peter d27b4997b9 IDEA-138441 Methods named like getters are wrongly treated as pure
don't track state for primitive get* methods
for reference-typed methods, track state only inside "if (getX() != null) ..."
flush dfa variables on non-pure getter-like calls
2015-05-18 17:02:51 +02:00
peter c577be8f4f dfa: correctly handle ""== Boolean.TRUE/FALSE" 2015-04-24 19:16:44 +02:00
peter 466bd18aff add hardcoded contracts for Guava checkArgument/checkState (IDEA-126005) 2015-04-20 17:06:34 +02:00
peter 96b1e4a3df IDEA-139392 "Method Invocation may produce NPE" warning after call to assertThat().isNotNull from Google Truth framework 2015-04-20 17:06:33 +02:00
peter ce9914e697 IDEA-139253 TYPE_USE @Nullable-Annotations don't work correctly with arrays 2015-04-16 19:11:46 +03:00
peter 51e23e6063 IDEA-139301 "Constant conditions & exceptions" flaggs nullable expression when implementing a method returning void 2015-04-16 19:11:45 +03:00
peter ecab324ae0 dfa: overriding @NotNull has precedence over super method @Nullable 2015-04-13 18:51:22 +03:00
peter 4ec8011316 relax "!null" contract checking to accept exceptions thrown (IDEA-133488) 2015-04-08 18:13:15 +02:00
peter eab2402c47 dfa: support non-initialized final field escaping in constructors (IDEA-137154) 2015-03-23 18:57:36 +01:00
peter c72c1bf7c6 dfa: mark ephemeral states even when there's no way of checking contract condition (IDEA-137604) 2015-03-17 13:03:44 +01:00
peter 8d2f9b07e8 contract nulls are compatible with array return types (IDEA-137323) 2015-03-06 14:59:53 +01:00
peter b74370435f dfa: check that states to be merged are really complementary (IDEA-136917) 2015-02-25 17:27:47 +01:00
peter fb5ddff5cf IDEA-136603 IDEA does not warn if annotated with @Nullable local variable is used for @NotNull parameter method 2015-02-17 15:55:07 +01:00
peter 03ddd9dcea IDEA-136580 "Contract violation" warnings are reported for manual method contract 2015-02-16 12:13:26 +01:00
peter a88ab17b3f IDEA-136079 "Contract violation" warnings are reported for inferred method contract for method with varargs 2015-02-06 16:11:11 +01:00
peter cd02f59555 IDEA-135846 Dfa should warn about qualifiers in method references 2015-02-02 12:42:56 +01:00