5 use Function::Parameters 'f';
7 my $add = f ($x, $y) { $x + $y };
11 ok !eval { Function::Parameters->import('g', 'h', 'i'); 1 };
13 for my $kw ('', '42', 'A::B', 'a b') {
14 ok !eval{ Function::Parameters->import($kw); 1 };
15 like $@, qr/valid identifier /;
18 use Function::Parameters 'func_a', 'meth_a';
20 func_a cat_a($x, $y) {
28 is cat_a('ab', 'cde'), 'abcde';
29 is tac_a('ab', 'cde'), 'cdeab';
31 use Function::Parameters {
36 func_b cat_b($x, $y) {
44 is cat_b('ab', 'cde'), 'abcde';
45 is tac_b('ab', 'cde'), 'cdeab';