diff options
author | Jesse Luehrs <doy@tozt.net> | 2013-07-10 16:43:46 -0400 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2013-07-10 16:44:17 -0400 |
commit | 7031ee9e2b385fd149cd121e3d5d01f99ac99eda (patch) | |
tree | 285b44972dade6a1a9f66fb95d7c0e8cf800cc12 /lib | |
parent | 85d4bad1e238a5e902cf390f023744c8e3dc1181 (diff) | |
download | exporter-lexical-7031ee9e2b385fd149cd121e3d5d01f99ac99eda.tar.gz exporter-lexical-7031ee9e2b385fd149cd121e3d5d01f99ac99eda.zip |
make this api a bit less dumb
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Exporter/Lexical.pm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/Exporter/Lexical.pm b/lib/Exporter/Lexical.pm index 8eaf1a2..56b0843 100644 --- a/lib/Exporter/Lexical.pm +++ b/lib/Exporter/Lexical.pm @@ -16,6 +16,8 @@ XSLoader::load( sub import { my $package = shift; + my %opts = @_; + my $caller = caller; my $import = sub { @@ -23,7 +25,7 @@ sub import { no strict 'refs'; \%{ $caller . '::' }; }; - my @exports = @{ $caller_stash->{EXPORT} }; + my @exports = @{ $opts{'-exports'} }; my %exports = map { $_ => \&{ $caller_stash->{$_} } } @exports; for my $export (keys %exports) { |