- or download this
# ...
107 sub foo {
...
110 => die "invalid x!" unless $x == 42;
111 print "Yay!"
112 # ...
- or download this
DB<6> $x = 43;
- or download this
use strict;
...
foo();
sub foo { my $x; $x = 43; if($x==42){print "DANGER Will Robinson!\n"
+}else{print "Yay!\n";}}
- or download this
main::(perldebugexample2.pl:3): foo();
DB<1> n
...
DB<2> n
DANGER Will Robinson!