in reply to Re^4: why such an error happened?
in thread why such an error happened?

$1 and $2 are statically assigned when the regex is being compiled. At that time the regex-engine does not yet know which --if any-- of the parentheses will match. So $1 will refer to what is between the first set of parentheses (counting from the left); $2 refers to the second set (counting from the left); etc. ...

In an (nested) alternation pattern (|) only one of these will ever match and that causes the warning.

In your case you can safely ignore it.

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James