TEST_EXCEPTION {
my
$l
= list 100 - 1,
"bottles"
;
die
"not what we wanted: "
. show(
$l
)
}
"not what we wanted: list(99, 'bottles')"
;
TEST { show cons 1, cons 2, 3 }
'improper_list(1, 2, 3)'
;
TEST { show improper_list(list(1, 3), 2) }
'improper_list(list(1, 3), 2)'
;
TEST {
regex_substitute
sub
{s/line \d+/line .../g},
show improper_list([1, 3], {
foo
=> list(
"bar"
,
sub
{
"f"
}) })
}
"improper_list([1, 3], +{foo => list('bar', sub { 'DUMMY' })})"
;
my
$s
;
TEST {
$s
= stream_iota->take(10);
show
$s
}
"lazyT { 'DUMMY' } 'FP::List::List'"
;
TEST {
$s
->rest->rest;
show
$s
}
"improper_list(0, 1, lazyT { 'DUMMY' } 'FP::List::List')"
;
TEST {
show * STDERR {IO}
}
"bless(IO(2), 'IO::File')"
;
1