Affects PMD Version:
6.13.0
Rule:
CyclomaticComplexity
Description:
I had a function with a high cyclomatic complexity. I started to reduce it, but even when it became a linear one, I still have the warning:
Description Resource Path Location Type
The method 'createContract(List, Method, ContractRunnerData)' has a cyclomatic complexity of 9. ContractCreationServiceImpl.java /cdd/src/main/java/com/kodekonveyor/cdd/build/impl line 32 PMD Marker (Prio 3)
I am using PMD Plug-in 4.2.0.v20190331-1136 in eclipse.
Tried to clear violations and check again, clean the source code and rebuild from eclipse, clean the source code with git clean -fdx
, refresh the project from disk, and all combinations thereof.
Code Sample demonstrating the issue:
This code sample still have the warning above:
@Override
public ContractInfo<ServiceType> createContract(
final List<ContractInfo<ServiceType>> contracts, final Method method,
final ContractRunnerData<ServiceType> data
) throws AssertionError, Throwable {
return null;
}
Running PMD through: [CLI | Ant | Maven | Gradle | Designer | Other]
eclipse
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4