There are two variants, how a renamed rule can be expressed in the
ruleset via a deprecated rule reference: referencing just the
new rule name or referencing the ruleset+new rule name. The latter
case was not covered yet, it was not detected, that the rule ref
references are rule in the same ruleset.
Fixes#2096
The fix introduced with #503 (fba00843bb523cbeb06157c4793ffc29bd9a6ee7)
was incomplete and didn't work:
* The logger uses the full class name insteand of simple name
* After we changed the log level of the logger, the logger
could be garbage collected before ApexLexer retrieves it and
thus the configuration could be lost
Fixes#2048
All XPath rules will have now type resolution enabled by default.
While this change is in core, it actually only affects Java, since
this is the only language which has a type resolution facade
registered in its language handler.
Fixes#1531
In case we determined, that the method argument is a method call,
then we skip now completly trying to determine the correct argument
type. It was half-way fixed before for the first if condition, but
we still evaluated e.g. the allocation expression in
print(new Integer(1).toString());
and wrongly assumed, the argument type would be an integer,
without taking into account the `toString()` method call.
The same happened with
privateBooleanMethod(s, "true".equals(s));
where we took the 2nd argument as a literal and assumed
it is a "String", while the method call result actually
is a boolean.
With this change now, the false positive is fixed.
However, since we don't determine the argument type at all, the
method is matched solely on argument count. This will obviously
lead to wrong matches if method overloading is used.
* Improve integration tests in pmd-dist to detect
warnings about deprecated attributes.
* Wrap the attribute value in a singleton list, to be able to distinguish
between no value (null in the list) and value not determined yet
(list is null).
* Add integration test for apex.
* Updated release notes
fixes#2020