X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=p5sagit%2FDevel-REPL.git;a=blobdiff_plain;f=lib%2FDevel%2FREPL%2FPlugin%2FCompletionDriver%2FMethods.pm;h=21c4e300ec04f6e234a86e349802be9cbff22d93;hp=4fa2292d4b860c30c84ee51d194dcd21edecbbab;hb=32d646c7c20ff26e8b0ae31b329fafb7094f6db7;hpb=30b459d4fbeb6f2406a3013c7cbcc46a6d0ccf0d diff --git a/lib/Devel/REPL/Plugin/CompletionDriver/Methods.pm b/lib/Devel/REPL/Plugin/CompletionDriver/Methods.pm index 4fa2292..21c4e30 100644 --- a/lib/Devel/REPL/Plugin/CompletionDriver/Methods.pm +++ b/lib/Devel/REPL/Plugin/CompletionDriver/Methods.pm @@ -2,7 +2,12 @@ package Devel::REPL::Plugin::CompletionDriver::Methods; use Devel::REPL::Plugin; use namespace::clean -except => [ 'meta' ]; -with 'Devel::REPL::Plugin::FindVariable'; +sub BEFORE_PLUGIN { + my $self = shift; + for (qw/Completion FindVariable/) { + $self->load_plugin($_); + } +} around complete => sub { my $orig = shift; @@ -52,8 +57,8 @@ around complete => sub { return $orig->(@_), grep { $_ =~ $re } - map { $_->{name} } - $metaclass->compute_all_applicable_methods; + map { $_->name } + $metaclass->get_all_methods; }; 1;