Describe the bug
the EC77 rule implementation is not accurate enough. see screenshot below.
the rule wants us to make a pattern as static and not declared directly in method.
But the problem is if the pattern is declared directly in code and use a string with variable concatenation, we can't declare this pattern is a static way.
Expected behavior
Check is the string pattern uses a variable (not static) in string pattern.
if yes, don't raise the issue because we can't declare it to a static way.
Screenshots

Software Versions
- SonarQube Version: 10.3
- Plugin Version: java plugin 1.4.3
Describe the bug
the EC77 rule implementation is not accurate enough. see screenshot below.
the rule wants us to make a pattern as static and not declared directly in method.
But the problem is if the pattern is declared directly in code and use a string with variable concatenation, we can't declare this pattern is a static way.
Expected behavior
Check is the string pattern uses a variable (not static) in string pattern.
if yes, don't raise the issue because we can't declare it to a static way.
Screenshots

Software Versions