Subject: | incorrect regexes /^foo|bar$/ instead of /^(foo|bar)$/ |
several places in the source code incorrectly check for regexes
of shape /^foo|bar$/ instead of /^(foo|bar)$/.
The former works, but there is a risk of matching other strings than
just "foo" and "bar", like "footage" or "carambar".
ack --nocolor --nogroup --nofilter -- "/\^\w+\|"
Context.pm:750: if ($args[0] =~ /^on|1$/i) {
Context.pm:754: elsif ($args[0] =~ /^off|0$/i) {
Directive.pm:653: die \$_tt_error if \$_tt_error->type
=~ /^return|stop\$/;
Stash.pm:78: if ($type =~ /^scalar|item$/) {
Stash.pm:84: elsif ($type =~ /^list|array$/) {