fix punctuation
[gitmo/Moose.git] / lib / Moose.pm
index bea53b9..901821a 100644 (file)
@@ -5,10 +5,9 @@ use warnings;
 use 5.008;
 
 use Scalar::Util 'blessed';
-use Carp         'confess';
+use Carp         'carp', 'confess';
 use Class::Load  'is_class_loaded';
 
-
 use Moose::Deprecated;
 use Moose::Exporter;
 
@@ -68,7 +67,10 @@ sub has {
     Moose->throw_error('Usage: has \'name\' => ( key => value, ... )')
         if @_ % 2 == 1;
 
-    my %options = ( definition_context => Moose::Util::_caller_info(), @_ );
+    my %context = Moose::Util::_caller_info;
+    $context{context} = 'has declaration';
+    $context{type} = 'class';
+    my %options = ( definition_context => \%context, @_ );
     my $attrs = ( ref($name) eq 'ARRAY' ) ? $name : [ ($name) ];
     $meta->add_attribute( $_, %options ) for @$attrs;
 }
@@ -90,6 +92,10 @@ our $SUPER_BODY;
 our @SUPER_ARGS;
 
 sub super {
+    if (@_) {
+        carp 'Arguments passed to super() are ignored';
+    }
+
     # This check avoids a recursion loop - see
     # t/bugs/super_recursion.t
     return if defined $SUPER_PACKAGE && $SUPER_PACKAGE ne caller();
@@ -459,7 +465,7 @@ for information on how to define a new type, and how to retrieve type meta-data)
 This will attempt to use coercion with the supplied type constraint to change
 the value passed into any accessors or constructors. You B<must> supply a type
 constraint, and that type constraint B<must> define a coercion. See
-L<Moose::Cookbook::Basics::Recipe5> for an example.
+L<Moose::Cookbook::Basics::HTTP_SubtypesAndCoercion> for an example.
 
 =item I<does =E<gt> $role_name>
 
@@ -637,15 +643,16 @@ cover here.
 See L<Metaclass and Trait Name Resolution> for details on how a trait name is
 resolved to a role name.
 
-Also see L<Moose::Cookbook::Meta::Recipe3> for a metaclass trait
-example.
+Also see L<Moose::Cookbook::Meta::Labeled_AttributeTrait> for a metaclass
+trait example.
 
 =item I<builder> => Str
 
-The value of this key is the name of the method that will be called to
-obtain the value used to initialize the attribute. See the L<builder
-option docs in Class::MOP::Attribute|Class::MOP::Attribute/builder>
-and/or L<Moose::Cookbook::Basics::Recipe8> for more information.
+The value of this key is the name of the method that will be called to obtain
+the value used to initialize the attribute. See the L<builder option docs in
+Class::MOP::Attribute|Class::MOP::Attribute/builder> and/or
+L<Moose::Cookbook::Basics::BinaryTree_BuilderAndLazyBuild> for more
+information.
 
 =item I<default> => SCALAR | CODE
 
@@ -787,14 +794,15 @@ superclass method with the same arguments as the original method.
 
 An C<augment> method, is a way of explicitly saying "I am augmenting this
 method from my superclass". Once again, the details of how C<inner> and
-C<augment> work is best described in the L<Moose::Cookbook::Basics::Recipe6>.
+C<augment> work is best described in the
+L<Moose::Cookbook::Basics::Document_AugmentAndInner>.
 
 =item B<inner>
 
 The keyword C<inner>, much like C<super>, is a no-op outside of the context of
 an C<augment> method. You can think of C<inner> as being the inverse of
 C<super>; the details of how C<inner> and C<augment> work is best described in
-the L<Moose::Cookbook::Basics::Recipe6>.
+the L<Moose::Cookbook::Basics::Document_AugmentAndInner>.
 
 =item B<blessed>
 
@@ -840,8 +848,8 @@ The lookup method for metaclasses is the same, except that it looks
 for a class matching B<Moose::Meta::$type::Custom::$metaclass_name>.
 
 If all this is confusing, take a look at
-L<Moose::Cookbook::Meta::Recipe3>, which demonstrates how to create an
-attribute trait.
+L<Moose::Cookbook::Meta::Labeled_AttributeTrait>, which demonstrates how to
+create an attribute trait.
 
 =head1 UNIMPORTING FUNCTIONS
 
@@ -868,7 +876,7 @@ to work. Here is an example:
 
 To learn more about extending Moose, we recommend checking out the
 "Extending" recipes in the L<Moose::Cookbook>, starting with
-L<Moose::Cookbook::Extending::Recipe1>, which provides an overview of
+L<Moose::Cookbook::Extending::ExtensionOverview>, which provides an overview of
 all the different ways you might extend Moose. L<Moose::Exporter> and
 L<Moose::Util::MetaRole> are the modules which provide the majority of the
 extension functionality, so reading their documentation should also be helpful.
@@ -936,14 +944,39 @@ not (UPDATE: so far so good).
 
 We offer both a mailing list and a very active IRC channel.
 
-The mailing list is L<moose@perl.org>. You must be subscribed to send
+The mailing list is L<mailto:moose@perl.org>. You must be subscribed to send
 a message. To subscribe, send an empty message to
-L<moose-subscribe@perl.org>
+L<mailto:moose-subscribe@perl.org>
 
 You can also visit us at C<#moose> on L<irc://irc.perl.org/#moose>
 This channel is quite active, and questions at all levels (on Moose-related
 topics ;) are welcome.
 
+=head1 WHAT DOES MOOSE STAND FOR?
+
+Moose doesn't stand for one thing in particular, however, if you want, here
+are a few of our favorites. Feel free to contribute more!
+
+=over 4
+
+=item * Make Other Object Systems Envious
+
+=item * Makes Object Orientation So Easy
+
+=item * Makes Object Orientation Spiffy- Er (sorry ingy)
+
+=item * Most Other Object Systems Emasculate
+
+=item * Moose Often Ovulate Sorta Early
+
+=item * Moose Offers Often Super Extensions
+
+=item * Meta Object Obligates Salivary Excitation
+
+=item * Meta Object Orientation Syntax Extensions
+
+=back
+
 =head1 ACKNOWLEDGEMENTS
 
 =over 4
@@ -1079,7 +1112,8 @@ John (jgoulah) Goulah wrote L<Moose::Cookbook::Snack::Keywords>.
 
 Jess (castaway) Robinson wrote L<Moose::Cookbook::Snack::Types>.
 
-Aran (bluefeet) Clary Deltac wrote L<Moose::Cookbook::Basics::Recipe9>.
+Aran (bluefeet) Clary Deltac wrote
+L<Moose::Cookbook::Basics::Genome_OverloadingSubtypesAndCoercion>.
 
 Anders (Debolaz) Nor Berle contributed L<Test::Moose> and L<Moose::Util>.