Perl5-IDEA icon indicating copy to clipboard operation
Perl5-IDEA copied to clipboard

Support export_to_level

Open zurom opened this issue 6 years ago • 4 comments

Methods exported by export_to_level highlighted with "Unable to find sub definition, declaration, constant definition or typeglob aliasing"

see https://perldoc.perl.org/Exporter.html

package A;

use Data::Dumper;
use Clone;

@ISA = qw(Exporter);

sub import {
    Data::Dumper->export_to_level(1, qw(Dumper));
    Clone->export_to_level(1);
}

########
package B;

use A;

sub foo {
  Dumper('bar'); # Unable to find sub definition, declaration, constant definition or typeglob aliasing
}   

zurom avatar Mar 06 '19 20:03 zurom

I'm aware of this method. But the problem that in most cases it's not declarative, but just a part of some logic: loop or something. And this can't be handled properly right now.

hurricup avatar Mar 07 '19 04:03 hurricup

Atm it's faster to support specific cpan modules explicitly, so let me know if there are any. This feature is not going to be implemented soon.

hurricup avatar Mar 07 '19 05:03 hurricup

But the problem that in most cases it's not declarative

Is it possible to implement at least declarative ones like PACKAGE->export_to_level?

zurom avatar Mar 11 '19 18:03 zurom

Up )

zurom avatar Jan 31 '24 16:01 zurom