org.sonar.l10n.py.rules.python.S6035.html Maven / Gradle / Ivy
Why is this an issue?
When an alternation contains multiple alternatives that consist of a single character, it can be rewritten as a character class. This should be
preferred because it is more efficient.
Noncompliant code example
r"a|b|c" # Noncompliant
Compliant solution
r"[abc]"
# or
r"[a-c]"
© 2015 - 2024 Weber Informatics LLC | Privacy Policy