SEARCH
NEW RPMS
DIRECTORIES
ABOUT
FAQ
VARIOUS
BLOG

 
 

perl-Syntax-Collector rpm build for : OpenSuSE. For other distributions click perl-Syntax-Collector.

Name : perl-Syntax-Collector
Version : 0.006 Vendor : obs://build_opensuse_org/devel:languages:perl
Release : lp155.1.1 Date : 2023-07-20 19:03:46
Group : Development/Libraries/Perl Source RPM : perl-Syntax-Collector-0.006-lp155.1.1.src.rpm
Size : 0.04 MB
Packager : https://www_suse_com/
Summary : collect a bundle of modules into one
Description :
Perl is such a flexible language that the language itself can be extended
from within. (Though much of the more interesting stuff needs XS hooks like
the Devel::Declare manpage.)

One problem with this is that it often requires a lot of declarations at
the top of your code, loading various syntax extensions. The the syntax
manpage module on CPAN addresses this somewhat by allowing you to load a
bunch of features in one line, provided each syntax feature implements the
necessary API:

use syntax qw/io maybe perform/;

However this introduces problems of its own. If we look at the code above,
it is non-obvious that it requires the Syntax::Feature::Io manpage, the
Syntax::Feature::Maybe manpage and the Syntax::Feature::Perform manpage,
which makes it difficult for automated tools such as the Module::Install
manpage to automatically calculate your code\'s dependencies.

Syntax::Collector to the rescue!

package Example::ProjectX::Syntax;
use 5.010;
use Syntax::Collector q/
use strict 0;
use warnings 0;
use feature 0 \':5.10\';
use Scalar::Util 1.21 qw(blessed);
/;

When you \'use Syntax::Collector\', you provide a list of modules to
\"collect\" into a single package (notice the \'q/.../\'). This list of modules
looks like a big string of Perl code that is going to be passed to \'eval\',
but don\'t let that fool you - it is not.

Each line must conform to the following pattern:

(use|no) MODULENAME VERSION (OTHERSTUFF)? ;

(Actually hash comments, and blank lines are also allowed.) The semantics
of all that is pretty much what you\'d expect, except that when MODULENAME
begins with \"Syntax::Feature::\" it\'s treated with some DWIMmery, and
\'install\' is called instead of \'import\'. Note that VERSION is required, but
if you don\'t care which version of a module you use, it\'s fine to set
VERSION to 0. (Yes, VERSION is even required for pragmata.)

Now, you ask... why stuff all that structured data into a string, and parse
it out again? Because to naive lexical analysis (e.g. the Module::Install
manpage) it really looks like a bunch of \"use\" lines, and not just a single
quoted string. This helps tools calculate the dependencies of your
collection; and thus the dependencies of other code that uses your
collection.

As well as providing an \'import\' method for your collection,
Syntax::Collector also provides a \'modules\' method, which can be called to
find out which modules a collection includes. Called in list context, it
returns a list. Called in scalar context, it returns a reference to a \'{
module => version }\' hash.

RPM found in directory: /packages/linux-pbone/ftp5.gwdg.de/pub/opensuse/repositories/devel:/languages:/perl:/CPAN-S/15.5/noarch

Content of RPM  Provides Requires

Download
ftp.icm.edu.pl  perl-Syntax-Collector-0.006-lp155.1.1.noarch.rpm
     

Provides :
perl(Syntax::Collector)
perl(Syntax::Collector::Collection)
perl-Syntax-Collector

Requires :
perl(:MODULE_COMPAT_5.26.1)
perl(Exporter::Tiny)
perl(Module::Runtime)
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1


Content of RPM :
/usr/lib/perl5/vendor_perl/5.26.1/Syntax
/usr/lib/perl5/vendor_perl/5.26.1/Syntax/Collector.pm
/usr/lib/perl5/vendor_perl/5.26.1/x86_64-linux-thread-multi
/usr/share/doc/packages/perl-Syntax-Collector
/usr/share/doc/packages/perl-Syntax-Collector/CONTRIBUTING
/usr/share/doc/packages/perl-Syntax-Collector/COPYRIGHT
/usr/share/doc/packages/perl-Syntax-Collector/CREDITS
/usr/share/doc/packages/perl-Syntax-Collector/Changes
/usr/share/doc/packages/perl-Syntax-Collector/LICENSE
/usr/share/doc/packages/perl-Syntax-Collector/README
/usr/share/doc/packages/perl-Syntax-Collector/doap.ttl
/usr/share/doc/packages/perl-Syntax-Collector/examples
/usr/share/doc/packages/perl-Syntax-Collector/examples/MyTest.pm
/usr/share/doc/packages/perl-Syntax-Collector/examples/basic.pl
/usr/share/man/man3/Syntax::Collector.3pm.gz

 
ICM