perl 1.0 patch 8: perl needed an eval operator and a symbolic debugger
[p5sagit/p5-mst-13.2.git] / t / op.eval
1 #!./perl
2
3 print "1..6\n";
4
5 eval 'print "ok 1\n";';
6
7 if ($@ eq '') {print "ok 2\n";} else {print "not ok 2\n";}
8
9 eval "\$foo\n    = # this is a comment\n'ok 3';";
10 print $foo,"\n";
11
12 eval "\$foo\n    = # this is a comment\n'ok 4\n';";
13 print $foo;
14
15 eval '
16 $foo =';                # this tests for a call through yyerror()
17 if ($@ =~ /line 2/) {print "ok 5\n";} else {print "not ok 5\n";}
18
19 eval '$foo = /';        # this tests for a call through fatal()
20 if ($@ =~ /Search/) {print "ok 6\n";} else {print "not ok 6\n";}