++ed by:
Reini Urban
and 1 contributors

# DESCRIPTION

optimize (and ... NO) to null if no gvsv/padsv, else (dor \$x) or do some SvGETMAGIC. (and NO) is always false, but all SVs must call their mg_get for all SVs before not.

# EXAMPLE1 gvsv

``````    \$ perl -MO=Concise,-exec -e'if (\$a and "x" eq "y") { print \$s;}'
1  <0> enter
2  <;> nextstate(main 3 -e:1) v:{
3  <\$> gvsv(*a) s
4  <|> and(other->5) sK/1
5      <\$> const(SPECIAL sv_no) s
6  <|> and(other->7) vK/1
7      <0> pushmark s
8      <\$> gvsv(*s) s
9      <@> print vK
a  <@> leave[1 ref] vKP/REFC``````

can be optimized to

``````    1  <0> enter
2  <;> nextstate(main 3 -e:1) v:{
3  <\$> gvsv(*a) s
4  <1> dor vK/1
a  <@> leave[1 ref] vKP/REFC``````

``````    \$ perl -MO=Concise,-exec -e'my \$a; if (\$a and "x" eq "y") { print \$s;}'

1  <0> enter
2  <;> nextstate(main 1 -e:1) v:{
...
4  <;> nextstate(main 4 -e:1) v:{
6  <|> and(other->7) sK/1
7      <\$> const[SPECIAL sv_no] s
8  <|> and(other->9) vK/1
9      <0> pushmark s
a      <#> gvsv[*s] s
b      <@> print vK
c  <@> leave[1 ref] vKP/REFC``````

can be optimized to

``````    1  <0> enter
2  <;> nextstate(main 1 -e:1) v:{
...
4  <;> nextstate(main 2 -e:1) v:{
``    \$ perl -MO=Concise,-exec -e'if ("x" eq "y" and \$a) { print \$s;}'``
``````    1  <0> enter