Skip to content
This repository has been archived by the owner on Oct 22, 2023. It is now read-only.

ES_COMPARING_STRINGS_WITH_EQ possibly not detected #56

Open
DAGobertGans opened this issue Sep 11, 2018 · 0 comments
Open

ES_COMPARING_STRINGS_WITH_EQ possibly not detected #56

DAGobertGans opened this issue Sep 11, 2018 · 0 comments

Comments

@DAGobertGans
Copy link

So I have the following java code to test whether the spotbugs maven and eclipse plugins behave as expected:

String a = "", b = "";
if (a == b);
String[] c = {""}, d = {""};
if (c.equals(d));

Now neither plugin reports the ES_COMPARING_STRINGS_WITH_EQ bug
but both do report the EC_BAD_ARRAY_COMPARE bug.
version 3.1.6, default effort level
What did I miss?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant