8 Devel::Declare->install_declarator(
9 'DeclareTest', 'method', DECLARE_PACKAGE | DECLARE_PROTO,
11 my ($name, $proto) = @_;
12 return 'my $self = shift;' unless defined $proto && $proto ne '@_';
13 return 'my ($self'.(length $proto ? ", ${proto}" : "").') = @_;';
16 my ($name, $proto, $sub, @rest) = @_;
17 if (defined $name && length $name) {
18 unless ($name =~ /::/) {
19 $name = "DeclareTest::${name}";
24 return wantarray ? ($sub, @rest) : $sub;
30 my ($test_method1, $test_method2, @test_list);
41 no warnings 'uninitialized';
42 print @{"_<t/debug.pl"};