Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP6
perl-Data-OptList
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Meta Configuration of Package perl-Data-OptList
<package name="perl-Data-OptList" project="openSUSE:Backports:SLE-15-SP6"> <title>Parse and validate simple name/value option pairs</title> <description> Hashes are great for storing named data, but if you want more than one entry for a name, you have to use a list of pairs. Even then, this is really boring to write: $values = [ foo => undef, bar => undef, baz => undef, xyz => { ... }, ]; Just look at all those undefs! Don't worry, we can get rid of those: $values = [ map { $_ => undef } qw(foo bar baz), xyz => { ... }, ]; Aaaauuugh! We've saved a little typing, but now it requires thought to read, and thinking is even worse than typing. With Data::OptList, you can do this instead: $values = Data::OptList::mkopt([ qw(foo bar baz), xyz => { ... }, ]); This works by assuming that any defined scalar is a name and any reference following a name is its value. Author: Ricardo SIGNES, <rjbs@cpan.org></description> </package>
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor