https://github.com/perigrin/perl-simple-lexical-export
https://github.com/perigrin/perl-simple-lexical-export
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/perigrin/perl-simple-lexical-export
- Owner: perigrin
- Created: 2023-07-31T20:35:30.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-30T16:33:14.000Z (about 1 year ago)
- Last Synced: 2025-02-10T10:31:26.990Z (5 months ago)
- Language: Perl
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# simple::lexical::export
This sets up a simple lexical exporter using the new
`builtin::export_lexically` and subroutine attributes to tag the functions we
want to export.```perl
$ cat lib/Source.pm
use 5.38.0;
use warnings;package Utils {
use simple::lexical::export;
sub frobnicate :export { ... }
sub frazzle :export(fry) { ... }
}$ cat foo.pl
class Foo {
use Utils;
method perform { frobincate() }
}
Foo->new()->perform;
````A better example will come later I hope.