Skip to content

Instantly share code, notes, and snippets.

@kan
Created January 13, 2013 11:22
Show Gist options
  • Save kan/4523622 to your computer and use it in GitHub Desktop.
Save kan/4523622 to your computer and use it in GitHub Desktop.
use Smart::Options;
my $argv = Smart::Options->new()->type(foo => 'Str')->parase('bar');
$argv->{foo} # => 'bar'
my $argv = Smart::Options->new()->type(foo => 'ArrayRef')->parase('bar');
$argv->{foo} # => ['bar']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment