Commit | Line | Data |
87a42246 |
1 | #!./perl |
2 | |
3 | BEGIN { |
88587957 |
4 | chdir 't' if -d 't'; |
87a42246 |
5 | if ($^O eq 'MacOS') { |
6 | @INC = qw(: ::lib ::macos:lib); |
88587957 |
7 | } else { |
8 | @INC = '../lib'; |
87a42246 |
9 | } |
10 | } |
11 | |
12 | $| = 1; |
13 | use warnings; |
14 | use strict; |
15 | use Config; |
16 | |
17 | print "1..1\n"; |
18 | |
19 | my $test = 1; |
20 | |
21 | sub ok { print "ok $test\n"; $test++ } |
22 | |
23 | my $a; |
24 | my $Is_VMS = $^O eq 'VMS'; |
25 | my $Is_MacOS = $^O eq 'MacOS'; |
26 | |
27 | my $path = join " ", map { qq["-I$_"] } @INC; |
d0c1fe9a |
28 | $path = '"-I../lib" "-Iperl_root:[lib]"' if $Is_VMS; # gets too long otherwise |
87a42246 |
29 | my $redir = $Is_MacOS ? "" : "2>&1"; |
30 | my $is_thread = $Config{use5005threads} && $Config{use5005threads} eq 'define'; |
31 | |
32 | if ($is_thread) { |
33 | print "# use5005threads: test $test skipped\n"; |
34 | } else { |
56034a21 |
35 | $a = `$^X $path "-MO=Showlex" -e "my \@one" $redir`; |
fd3fb69e |
36 | print "# [$a]\nnot " unless $a =~ /sv_undef.*PVNV.*\@one.*sv_undef.*AV/s; |
87a42246 |
37 | } |
38 | ok; |