Curly brace quantifiers in regular expressions can be used to have a more fine-grained control over how many times the character or the sub-expression preceeding them should occur. They can be used to match an expression exactly n times with {n}, between n and m times with {n,m}, or at least n times with {n,}. In some cases, using such a quantifier is superfluous for the semantic of the regular expression, and it can be removed to improve readability. This rule raises an issue when one of the following quantifiers is encountered:

Noncompliant Code Example

"ab{1,1}c"
"ab{1}c"
"ab{0,0}c"
"ab{0}c"

Compliant Solution

"abc"
"ac"