devel/p5-Lexical-Import 0.002_2 FreeBSD
Clean imports from package-exporting modules
- System
- FreeBSD
- Repository
- FreeBSD ports
- Maintainer
- [email protected]
- License
- ART10, GPLv1+
- Categories
- devel, perl5
- Package size
- 13.4 KiB, 24.6 KiB installed
Description
Lexical::Import allows functions and other items, from a separate module, to be imported into the lexical namespace (as implemented by Lexical::Var), when the exporting module exports non-lexically to a package in the traditional manner. This is a translation layer, to help code written in the new way to use modules written in the old way.
A lexically-imported item takes effect from the end of the definition statement up to the end of the immediately enclosing block, except where it is shadowed within a nested block. This is the same lexical scoping that the my, our, and state keywords supply. Within its scope, any use of the single-part name of the item (e.g., "$foo") refers directly to that item, regardless of what is in any package. Explicitly package-qualified names (e.g., "$main::foo") still refer to the package. There is no conflict between a lexical name definition and the same name in any package.
This mechanism only works on Perl 5.11.2 and later. Prior to that, it is impossible for lexical subroutine imports to work for bareword subroutine calls. (See "BUGS" in Lexical::Var for details.) Other kinds of lexical importing are possible on earlier Perls, but because this is such a critical kind of usage in most code, this module will ensure that it works, for convenience. If the limited lexical importing is desired on earlier Perls, use Lexical::Var directly.
In the other systems
| System | Port | Version |
|---|---|---|
| FreeBSD | devel/p5-Lexical-Import | 0.002_2 |
| DragonFly | devel/p5-Lexical-Import | 0.002_2 |
| HardenedBSD | devel/p5-Lexical-Import | 0.002_2 |
| GhostBSD | devel/p5-Lexical-Import | 0.002_2 |
Install
Binary package:
pkg install p5-Lexical-Import
From the ports tree:
cd /usr/ports/devel/p5-Lexical-Import/ && make install clean
To depend on this port in another port's Makefile:
RUN_DEPENDS= p5-Lexical-Import>0:devel/p5-Lexical-Import
Packages
The version each package repository carries. “-” means the repository builds no package of it, “n/a” that there is no such repository.
| Repository | aarch64 | amd64 | armv6 | armv7 | i386 |
|---|---|---|---|---|---|
| FreeBSD:14:latest | 0.002_2 | 0.002_2 | 0.002_2 | 0.002_2 | 0.002_2 |
| FreeBSD:14:quarterly | 0.002_2 | 0.002_2 | n/a | 0.002_2 | 0.002_2 |
| FreeBSD:15:latest | 0.002_2 | 0.002_2 | n/a | 0.002_2 | 0.002_2 |
| FreeBSD:15:quarterly | 0.002_2 | 0.002_2 | n/a | n/a | n/a |
| FreeBSD:16:latest | 0.002_2 | 0.002_2 | n/a | n/a | n/a |
| FreeBSD:16:quarterly | n/a | n/a | n/a | n/a | n/a |
Dependencies
As this port's Makefile names them.
Build 3
p5-Lexical-Var>=0.006: devel/p5-Lexical-Varp5-Module-Runtime>=0.011: devel/p5-Module-Runtimep5-Params-Classify>=0: devel/p5-Params-Classify
Runtime 3
p5-Lexical-Var>=0.006: devel/p5-Lexical-Varp5-Module-Runtime>=0.011: devel/p5-Module-Runtimep5-Params-Classify>=0: devel/p5-Params-Classify
Test 2
p5-Test-Pod>=1: devel/p5-Test-Podp5-Test-Pod-Coverage>=0: devel/p5-Test-Pod-Coverage
The full lists below include those, and their dependencies in turn.
Build dependencies 5
No port depends on this one.
Configuration
No options to configure.
- USES
- perl5
- Service scripts
- none
Files
pkg-plist 3
- %%SITE_ARCH%%/Lexical/Import.pm
- %%SITE_ARCH%%/auto/Lexical/Import/Import.so
- %%PERL5_MAN3%%/Lexical::Import.3.gz
distinfo 1
| File | Size | SHA256 |
|---|---|---|
| Lexical-Import-0.002.tar.gz | 11432 | 5a555f870f09776d2d94b222a07c6a549896da751175bcc6714f1160b21d11fe |
Master sites 1
- CPAN
Commit history 0
No commits in the history this site was built from.