Merge branch 'master' of git@github.com:bobtfish/moosex-getopt
Tomas Doran [Thu, 27 Aug 2009 00:27:06 +0000 (01:27 +0100)]
* 'master' of git@github.com:bobtfish/moosex-getopt:
  Cleanup test, removing unneeded code serving no purpose or tested elsewhere
  Enable the argv argument to the constructor.

1  2 
lib/MooseX/Getopt.pm

diff --combined lib/MooseX/Getopt.pm
@@@ -69,7 -69,7 +69,7 @@@ sub new_with_options 
  sub _parse_argv {
      my ( $class, %params ) = @_;
  
-     local @ARGV = @{ $params{argv} || \@ARGV };
+     local @ARGV = @{ $params{params}{argv} || \@ARGV };
  
      my ( $opt_spec, $name_to_init_arg ) = ( HAVE_GLD ? $class->_gld_spec(%params) : $class->_traditional_spec(%params) );
  
@@@ -285,8 -285,8 +285,8 @@@ to have C<MooseX::Getopt> ignore your a
  
  By default, attributes which start with an underscore are not given
  commandline argument support, unless the attribute's metaclass is set
 -to L<MooseX::Getopt::Meta::Attribute>. If you don't want you accessors
 -to have the leading underscore in thier name, you can do this:
 +to L<MooseX::Getopt::Meta::Attribute>. If you don't want your accessors
 +to have the leading underscore in their name, you can do this:
  
    # for read/write attributes
    has '_foo' => (accessor => 'foo', ...);
@@@ -438,7 -438,7 +438,7 @@@ B<documentation> option for each attrib
    --help
    --usage
  
 -If you have L<Getopt::Long::Descriptive> a the C<usage> param is also passed to
 +If you have L<Getopt::Long::Descriptive> the C<usage> param is also passed to
  C<new>.
  
  =item B<ARGV>