5 eval 'print "ok 1\n";';
7 if ($@ eq '') {print "ok 2\n";} else {print "not ok 2\n";}
9 eval "\$foo\n = # this is a comment\n'ok 3';";
12 eval "\$foo\n = # this is a comment\n'ok 4\n';";
16 $foo ='; # this tests for a call through yyerror()
17 if ($@ =~ /line 2/) {print "ok 5\n";} else {print "not ok 5\n";}
19 eval '$foo = /'; # this tests for a call through fatal()
20 if ($@ =~ /Search/) {print "ok 6\n";} else {print "not ok 6\n";}