java:S2885 does not recognize static field initialized with DateFormat.getDateInstance()

Hi Holger,

Each call to DateFormat.getDateInstance() return a new SimpleDateFormat that should not be used in a multi-thread context. So yes, the rule S2885 should also report the above case. It’s called a false-negative and I have created the SONARJAVA-3400 ticket to improve the rule.

Thanks for your feedback,

Alban