current line and not know it; exposed by change#5004; manifested
as parse failure of C<{require 5.003}>
p4raw-link: @5004 on //depot/perl:
18b095192e336ba31465f4d3dab1ecc90871c3a9
p4raw-id: //depot/perl@5061
# don't make this lexical
$i = 1;
-print "1..16\n";
+print "1..20\n";
sub do_require {
%INC = ();
close REQ;
}
+eval {require 5.005};
+print "# $@\nnot " if $@;
+print "ok ",$i++,"\n";
+
+eval { require 5.005 };
+print "# $@\nnot " if $@;
+print "ok ",$i++,"\n";
+
+eval { require 5.005; };
+print "# $@\nnot " if $@;
+print "ok ",$i++,"\n";
+
+eval {
+ require 5.005
+};
+print "# $@\nnot " if $@;
+print "ok ",$i++,"\n";
+
# new style version numbers
eval { require v5.5.630; };
unshift @INC, '../lib';
}
-print "1..14\n";
+print "1..15\n";
my $i = 1;
+eval "use 5.000"; # implicit semicolon
+if ($@) {
+ print STDERR $@,"\n";
+ print "not ";
+}
+print "ok ",$i++,"\n";
eval "use 5.000;";
if ($@) {
if (*d == 'v')
d++;
for (; isDIGIT(*d) || *d == '_' || *d == '.'; d++);
- if ((*d == ';' || isSPACE(*d)) && *(skipspace(d)) != ',') {
+ if (*d == ';' || isSPACE(*d) || *d == '}' || !*d) {
s = scan_num(s);
/* real VERSION number -- GBARR */
version = yylval.opval;