3 # This file is for concatenation tests that require test.pl.
5 # t/opbasic/concat.t cannot use test.pl as
6 # it needs to avoid using concatenation in
18 skip("no encoding pragma in EBCDIC", 1) if $::IS_EBCDIC;
19 skip_if_miniperl("no dynamic loading on miniperl, no Encode", 1);
20 fresh_perl_is <<'end', "ok\n", {},
21 no warnings 'deprecated';
23 map { "a" . $a } ((1)x5000);
26 "concat does not lose its stack pointer after utf8 upgrade [perl #78674]";
29 # This test is in the file because overload.pm uses concatenation.
30 { package o; use overload '""' => sub { $_[0][0] } }
31 $x = bless[chr 256],o::;
36 is $x, "\xff\x{101}\x{101}", '.= is not confused by changing utf8ness';
38 # Ops should not share the same TARG between recursion levels. This may
39 # affect other ops, too, but concat seems more susceptible to this than
40 # others, since it can call itself recursively. (Where else would I put
42 fresh_perl_is <<'end', "tmp\ntmp\n", {},
51 package Path::Class::Dir;
52 use overload q[""] => sub { ::canonpath("tmp") };
55 print canonpath("tmp"), "\n";
56 print canonpath(bless {},"Path::Class::Dir"), "\n";
58 "recursive concat does not share TARGs";