Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Remove all trailing whitespace

Some packages still had a NAME header in the pod, instead of an ABSTRACT comment
  • Loading branch information...
commit 064a13a3104c7c38981bdc571b130da00b59945a 1 parent f899cf3
@autarch autarch authored
View
2  benchmarks/cmop/lib/MOP/Immutable/Point.pm
@@ -11,7 +11,7 @@ __PACKAGE__->meta->add_attribute('y' => (accessor => 'y'));
sub clear {
my $self = shift;
$self->x(0);
- $self->y(0);
+ $self->y(0);
}
__PACKAGE__->meta->make_immutable;
View
4 benchmarks/cmop/lib/MOP/Immutable/Point3D.pm
@@ -12,11 +12,11 @@ __PACKAGE__->meta->add_attribute('z' => (accessor => 'z'));
sub clear {
my $self = shift;
$self->SUPER::clear();
- $self->z(0);
+ $self->z(0);
}
__PACKAGE__->meta->make_immutable;
1;
-__END__
+__END__
View
4 benchmarks/cmop/lib/MOP/Installed/Point.pm
@@ -18,9 +18,9 @@ sub new {
sub clear {
my $self = shift;
$self->x(0);
- $self->y(0);
+ $self->y(0);
}
1;
-__END__
+__END__
View
4 benchmarks/cmop/lib/MOP/Installed/Point3D.pm
@@ -14,9 +14,9 @@ __PACKAGE__->meta->add_attribute('z' => (accessor => 'z'));
sub clear {
my $self = shift;
$self->SUPER::clear();
- $self->z(0);
+ $self->z(0);
}
1;
-__END__
+__END__
View
4 benchmarks/cmop/lib/MOP/Point.pm
@@ -16,9 +16,9 @@ sub new {
sub clear {
my $self = shift;
$self->x(0);
- $self->y(0);
+ $self->y(0);
}
1;
-__END__
+__END__
View
4 benchmarks/cmop/lib/MOP/Point3D.pm
@@ -12,9 +12,9 @@ __PACKAGE__->meta->add_attribute('z' => (accessor => 'z'));
sub clear {
my $self = shift;
$self->SUPER::clear();
- $self->z(0);
+ $self->z(0);
}
1;
-__END__
+__END__
View
2  benchmarks/cmop/lib/Plain/Point.pm
@@ -7,7 +7,7 @@ use warnings;
sub new {
my ( $class, %params ) = @_;
-
+
return bless {
x => $params{x} || 10,
y => $params{y},
View
122 eg/class_browser.pl
@@ -21,8 +21,8 @@
Class::MOP::Browser::Server;
our @ISA = qw(HTTP::Server::Simple::CGI);
sub handle_request { ::process_template() }
- }
- Class::MOP::Browser::Server->new()->run();
+ }
+ Class::MOP::Browser::Server->new()->run();
}
else {
print CGI::header();
@@ -41,16 +41,16 @@
'deparse_method' => \&::deparse_method,
'deparse_item' => \&::deparse_item,
}
- ) or warn Template->error;
+ ) or warn Template->error;
}
}
-sub get_all_metaclasses {
- sort { $a->name cmp $b->name } Class::MOP::get_all_metaclass_instances()
+sub get_all_metaclasses {
+ sort { $a->name cmp $b->name } Class::MOP::get_all_metaclass_instances()
}
-
-sub get_metaclass_by_name {
- Class::MOP::get_metaclass_by_name(@_);
+
+sub get_metaclass_by_name {
+ Class::MOP::get_metaclass_by_name(@_);
}
sub deparse_method {
@@ -65,9 +65,9 @@ sub deparse_item {
return $item unless ref $item;
local $Data::Dumper::Deparse = 1;
local $Data::Dumper::Indent = 1;
- my $dumped = Dumper $item;
+ my $dumped = Dumper $item;
$dumped =~ s/^\$VAR1\s=\s//;
- $dumped =~ s/\;$//;
+ $dumped =~ s/\;$//;
return _clean_deparse_code($dumped);
}
@@ -76,11 +76,11 @@ sub _clean_deparse_code {
my @cleaned;
foreach (@body) {
next if /^\s+use/;
- next if /^\s+BEGIN/;
- next if /^\s+package/;
+ next if /^\s+BEGIN/;
+ next if /^\s+package/;
push @cleaned => $_;
- }
- return (join "\n" => @cleaned);
+ }
+ return (join "\n" => @cleaned);
}
1;
@@ -116,52 +116,52 @@ sub _clean_deparse_code {
border: 1px dotted green;
}
-A {
+A {
font-family: arial;
- font-size: 12px;
+ font-size: 12px;
color: black;
text-decoration: none;
}
A:hover {
- text-decoration: underline;
+ text-decoration: underline;
}
-
-td.lightblue {
- background-color: #99BBFF;
- border-right: 1px solid #336699;
- border-bottom: 1px solid #336699;
- border-top: 1px solid #BBDDFF;
- border-left: 1px solid #BBDDFF;
+
+td.lightblue {
+ background-color: #99BBFF;
+ border-right: 1px solid #336699;
+ border-bottom: 1px solid #336699;
+ border-top: 1px solid #BBDDFF;
+ border-left: 1px solid #BBDDFF;
}
-td.grey {
- background-color: #CCCCCC;
- border-right: 1px solid #888888;
- border-bottom: 1px solid #888888;
- border-top: 1px solid #DDDDDD;
- border-left: 1px solid #DDDDDD;
+td.grey {
+ background-color: #CCCCCC;
+ border-right: 1px solid #888888;
+ border-bottom: 1px solid #888888;
+ border-top: 1px solid #DDDDDD;
+ border-left: 1px solid #DDDDDD;
}
-td.manila {
+td.manila {
background-color: #FFDD99;
- border-right: 2px solid #CC9933;
- border-bottom: 2px solid #CC9933;
- border-top: 2px solid #FFFFBB;
- border-left: 2px solid #FFFFBB;
+ border-right: 2px solid #CC9933;
+ border-bottom: 2px solid #CC9933;
+ border-top: 2px solid #FFFFBB;
+ border-left: 2px solid #FFFFBB;
}
-td.darkgreen {
- background-color: #33CC33;
- border-right: 1px solid #009900;
- border-bottom: 1px solid #009900;
- color: #CCFFCC;
+td.darkgreen {
+ background-color: #33CC33;
+ border-right: 1px solid #009900;
+ border-bottom: 1px solid #009900;
+ color: #CCFFCC;
}
-td.lightgreen {
- background-color: #AAFFAA;
- border-right: 1px solid #33FF33;
- border-bottom: 1px solid #33FF33;
+td.lightgreen {
+ background-color: #AAFFAA;
+ border-right: 1px solid #33FF33;
+ border-bottom: 1px solid #33FF33;
}
</style>
@@ -170,7 +170,7 @@ sub _clean_deparse_code {
<h1>Class::MOP Browser</h1>
<table bgcolor='#CCCCCC' cellpadding='0' cellspacing='0' border='0' align='center' height='400'>
<tr valign='top'>
-
+
<td rowspan='2' width='200'><table cellspacing='0' cellpadding='5' border='0' width='100%'>
[% FOREACH metaclass IN get_all_metaclasses() %]
<tr>
@@ -183,10 +183,10 @@ sub _clean_deparse_code {
[% END %]
</table></td>
<td height='10' width='250'><table cellspacing='0' cellpadding='5' border='0' width='100%'>
- <tr align='center'>
+ <tr align='center'>
[% FOREACH area_name IN [ 'attributes', 'methods', 'superclasses' ] %]
[% IF q.param('class') %]
- [% IF area == area_name %]
+ [% IF area == area_name %]
<td class='manila'><b>[% area_name %]</b></td>
[% ELSE %]
<td class='lightblue'><a href='?class=[% q.param('class') %]&area=[% area_name %]'>[% area_name %]</a></td>
@@ -200,13 +200,13 @@ sub _clean_deparse_code {
<td valign='top' rowspan='2' class='lightgreen' width='450'>
<table cellspacing='0' cellpadding='3' border='0'>
- <tr>
- <td class='darkgreen' width='100'></td>
- <td class='darkgreen' width='350'></td>
- </tr>
+ <tr>
+ <td class='darkgreen' width='100'></td>
+ <td class='darkgreen' width='350'></td>
+ </tr>
[% IF q.param('class') && area == 'attributes' && q.param('attr') %]
- [%
+ [%
meta = get_metaclass_by_name(q.param('class'))
attr = meta.get_attribute(q.param('attr'))
%]
@@ -221,7 +221,7 @@ sub _clean_deparse_code {
[% ELSIF q.param('class') && area == 'methods' && q.param('method') %]
- [%
+ [%
meta = get_metaclass_by_name(q.param('class'))
method = meta.get_method(q.param('method'))
%]
@@ -235,7 +235,7 @@ sub _clean_deparse_code {
<tr>
<td class='darkgreen' align='right' valign='top'>body</td>
<td class='lightgreen'><pre>[% deparse_method(method) %]</pre></td>
- </tr>
+ </tr>
[% END %]
</table></td>
@@ -253,31 +253,31 @@ sub _clean_deparse_code {
[% FOREACH method IN meta.get_method_list.sort %]
<tr>
[% IF q.param('method') == method %]
- <td class='darkgreen'><b>[% method %]</b></td>
+ <td class='darkgreen'><b>[% method %]</b></td>
[% ELSE %]
<td class='manila'><a href='?class=[% q.param('class') %]&area=[% q.param('area') %]&method=[% method %]'>[% method %]</a></td>
[% END %]
</tr>
- [% END %]
+ [% END %]
[% END %]
[% IF area == 'attributes' %]
[% FOREACH attr IN meta.get_attribute_list.sort %]
<tr>
[% IF q.param('attr') == attr %]
- <td class='darkgreen'><b>[% attr %]</b></td>
+ <td class='darkgreen'><b>[% attr %]</b></td>
[% ELSE %]
<td class='manila'><a href='?class=[% q.param('class') %]&area=[% q.param('area') %]&attr=[% attr %]'>[% attr %]</a></td>
[% END %]
</tr>
- [% END %]
- [% END %]
+ [% END %]
+ [% END %]
[% IF area == 'superclasses' %]
[% FOREACH super IN meta.superclasses.sort %]
<tr>
<td class='manila'><a href='?class=[% super %]'>[% super %]</a></td>
</tr>
- [% END %]
- [% END %]
+ [% END %]
+ [% END %]
</table></div></td>
[% END %]
View
28 lib/Class/MOP/Attribute.pm
@@ -110,26 +110,26 @@ sub initialize_instance_slot {
# attribute's default value (if it has one)
if(defined $init_arg and exists $params->{$init_arg}){
$self->_set_initial_slot_value(
- $meta_instance,
+ $meta_instance,
$instance,
$params->{$init_arg},
);
- }
+ }
elsif (exists $self->{'default'}) {
$self->_set_initial_slot_value(
- $meta_instance,
+ $meta_instance,
$instance,
$self->default($instance),
);
- }
+ }
elsif (defined( my $builder = $self->{'builder'})) {
if ($builder = $instance->can($builder)) {
$self->_set_initial_slot_value(
- $meta_instance,
+ $meta_instance,
$instance,
$instance->$builder,
);
- }
+ }
else {
confess(ref($instance)." does not support builder method '". $self->{'builder'} ."' for attribute '" . $self->name . "'");
}
@@ -163,8 +163,8 @@ sub _make_initializer_writer_callback {
};
}
-sub get_read_method {
- my $self = shift;
+sub get_read_method {
+ my $self = shift;
my $reader = $self->reader || $self->accessor;
# normal case ...
return $reader unless ref $reader;
@@ -173,19 +173,19 @@ sub get_read_method {
return $name;
}
-sub get_write_method {
+sub get_write_method {
my $self = shift;
- my $writer = $self->writer || $self->accessor;
+ my $writer = $self->writer || $self->accessor;
# normal case ...
return $writer unless ref $writer;
# the HASH ref case
my ($name) = %$writer;
- return $name;
+ return $name;
}
sub get_read_method_ref {
my $self = shift;
- if ((my $reader = $self->get_read_method) && $self->associated_class) {
+ if ((my $reader = $self->get_read_method) && $self->associated_class) {
return $self->associated_class->get_method($reader);
}
else {
@@ -204,8 +204,8 @@ sub get_read_method_ref {
}
sub get_write_method_ref {
- my $self = shift;
- if ((my $writer = $self->get_write_method) && $self->associated_class) {
+ my $self = shift;
+ if ((my $writer = $self->get_write_method) && $self->associated_class) {
return $self->associated_class->get_method($writer);
}
else {
View
20 lib/Class/MOP/Class.pm
@@ -27,7 +27,7 @@ sub initialize {
my $class = shift;
my $package_name;
-
+
if ( @_ % 2 ) {
$package_name = shift;
} else {
@@ -102,7 +102,7 @@ sub _construct_class_instance {
}
# and check the metaclass compatibility
- $meta->_check_metaclass_compatibility();
+ $meta->_check_metaclass_compatibility();
Class::MOP::store_metaclass_by_name($package_name, $meta);
@@ -716,7 +716,7 @@ sub get_meta_instance {
sub _create_meta_instance {
my $self = shift;
-
+
my $instance = $self->instance_metaclass->new(
associated_metaclass => $self,
attributes => [ $self->get_all_attributes() ],
@@ -997,18 +997,18 @@ sub class_precedence_list {
my $self = shift;
my $name = $self->name;
- unless (Class::MOP::IS_RUNNING_ON_5_10()) {
+ unless (Class::MOP::IS_RUNNING_ON_5_10()) {
# NOTE:
# We need to check for circular inheritance here
- # if we are are not on 5.10, cause 5.8 detects it
- # late. This will do nothing if all is well, and
+ # if we are are not on 5.10, cause 5.8 detects it
+ # late. This will do nothing if all is well, and
# blow up otherwise. Yes, it's an ugly hack, better
- # suggestions are welcome.
+ # suggestions are welcome.
# - SL
- ($name || return)->isa('This is a test for circular inheritance')
+ ($name || return)->isa('This is a test for circular inheritance')
}
- # if our mro is c3, we can
+ # if our mro is c3, we can
# just grab the linear_isa
if (mro::get_mro($name) eq 'c3') {
return @{ mro::get_linear_isa($name) }
@@ -1016,7 +1016,7 @@ sub class_precedence_list {
else {
# NOTE:
# we can't grab the linear_isa for dfs
- # since it has all the duplicates
+ # since it has all the duplicates
# already removed.
return (
$name,
View
6 lib/Class/MOP/Deprecated.pm
@@ -8,14 +8,12 @@ use Package::DeprecationManager -deprecations => {
1;
+# ABSTRACT: Manages deprecation warnings for Class::MOP
+
__END__
=pod
-=head1 NAME
-
-Class::MOP::Deprecated - Manages deprecation warnings for Class::MOP
-
=head1 DESCRIPTION
use Class::MOP::Deprecated -api_version => $version;
View
6 lib/Class/MOP/Method/Generated.pm
@@ -63,14 +63,12 @@ sub _compile_code {
1;
+# ABSTRACT: Abstract base class for generated methods
+
__END__
=pod
-=head1 NAME
-
-Class::MOP::Method::Generated - Abstract base class for generated methods
-
=head1 DESCRIPTION
This is a C<Class::MOP::Method> subclass which is subclassed by
View
6 lib/Class/MOP/MiniTrait.pm
@@ -33,14 +33,12 @@ require Class::MOP;
1;
+# ABSTRACT: Extremely limited trait application
+
__END__
=pod
-=head1 NAME
-
-Class::MOP::MiniTrait - Extremely limited trait application
-
=head1 DESCRIPTION
This package provides a single function, C<apply>, which does a half-assed job
View
8 lib/Class/MOP/Module.pm
@@ -29,12 +29,12 @@ sub _new {
} => $class;
}
-sub version {
+sub version {
my $self = shift;
${$self->get_or_add_package_symbol('$VERSION')};
}
-sub authority {
+sub authority {
my $self = shift;
${$self->get_or_add_package_symbol('$AUTHORITY')};
}
@@ -90,10 +90,6 @@ __END__
=pod
-=head1 NAME
-
-Class::MOP::Module - Module Meta Object
-
=head1 DESCRIPTION
A module is essentially a L<Class::MOP::Package> with metadata, in our
View
18 lib/Class/MOP/Object.pm
@@ -9,7 +9,7 @@ use Scalar::Util 'blessed';
# introspection
-sub meta {
+sub meta {
require Class::MOP::Class;
Class::MOP::Class->initialize(blessed($_[0]) || $_[0]);
}
@@ -19,15 +19,15 @@ sub _new {
}
# RANT:
-# Cmon, how many times have you written
+# Cmon, how many times have you written
# the following code while debugging:
-#
-# use Data::Dumper;
+#
+# use Data::Dumper;
# warn Dumper $obj;
#
-# It can get seriously annoying, so why
+# It can get seriously annoying, so why
# not just do this ...
-sub dump {
+sub dump {
my $self = shift;
require Data::Dumper;
local $Data::Dumper::Maxdepth = shift || 1;
@@ -93,14 +93,12 @@ sub _get_compatible_metaclass_by_subclassing {
1;
+# ABSTRACT: Base class for metaclasses
+
__END__
=pod
-=head1 NAME
-
-Class::MOP::Object - Base class for metaclasses
-
=head1 DESCRIPTION
This class is a very minimal base class for metaclasses.
View
5 lib/Class/MOP/Package.pm
@@ -22,8 +22,7 @@ sub initialize {
my $package_name = delete $options{package};
- # we hand-construct the class
- # until we can bootstrap it
+ # we hand-construct the class until we can bootstrap it
if ( my $meta = Class::MOP::get_metaclass_by_name($package_name) ) {
return $meta;
} else {
@@ -187,7 +186,7 @@ sub _new {
# Attributes
# NOTE:
-# all these attribute readers will be bootstrapped
+# all these attribute readers will be bootstrapped
# away in the Class::MOP bootstrap section
sub _package_stash {
View
6 lib/Moose/Deprecated.pm
@@ -14,14 +14,12 @@ use Package::DeprecationManager 0.07 -deprecations => {
1;
+# ABSTRACT: Manages deprecation warnings for Moose
+
__END__
=pod
-=head1 NAME
-
-Moose::Deprecated - Manages deprecation warnings for Moose
-
=head1 DESCRIPTION
use Moose::Deprecated -api_version => $version;
View
9 lib/Moose/Manual/Support.pod
@@ -1,9 +1,10 @@
-=pod
+package Moose::Manual::Support
-=head1 NAME
+# ABSTRACT: Policies regarding support, releases, and compatibility.
-Moose::Manual::Support - Policies regarding support, releases, and
-compatibility.
+__END__
+
+=pod
=head1 SUPPORT POLICY
View
2  lib/Moose/Meta/Attribute.pm
@@ -80,7 +80,7 @@ sub _inline_throw_error {
sub new {
my ($class, $name, %options) = @_;
$class->_process_options($name, \%options) unless $options{__hack_no_process_options}; # used from clone()... YECHKKK FIXME ICKY YUCK GROSS
-
+
delete $options{__hack_no_process_options};
my %attrs =
View
2  lib/Moose/Meta/Attribute/Native/Trait/Hash.pm
@@ -116,7 +116,7 @@ This method does not accept any arguments.
=item B<count>
-Returns the number of elements in the hash. Also useful for not empty:
+Returns the number of elements in the hash. Also useful for not empty:
C<< has_options => 'count' >>.
This method does not accept any arguments.
View
8 t/cmop/class_precedence_list.t
@@ -11,7 +11,7 @@ use Class::MOP::Class;
A
/ \
B C
- \ /
+ \ /
D
=cut
@@ -73,7 +73,7 @@ ok($@, '... recursive inheritance breaks correctly :)');
| A |
| / \ |
+->B C-+
- \ /
+ \ /
D
=cut
@@ -101,8 +101,8 @@ is_deeply(
=pod
-Test all the class_precedence_lists
-using Perl's own dispatcher to check
+Test all the class_precedence_lists
+using Perl's own dispatcher to check
against.
=cut
View
7 t/cmop/random_eval_bug.t
@@ -7,9 +7,10 @@ use Class::MOP;
=pod
-This tests a bug which is fixed in 0.22 by
-localizing all the $@'s around any evals.
-This a real pain to track down.
+This tests a bug which is fixed in 0.22 by localizing all the $@'s around any
+evals.
+
+This a real pain to track down.
Moral of the story:
View
5 t/metaclasses/moose_exporter.t
@@ -273,17 +273,16 @@ use Test::Requires {
{
package MooseX::OverridingSugar::PassThru;
-
+
sub with {
my $caller = shift->name;
return $caller . ' called with';
}
-
+
Moose::Exporter->setup_import_methods(
with_meta => ['with'],
also => 'MooseX::OverridingSugar',
);
-
}
{

0 comments on commit 064a13a

Please sign in to comment.
Something went wrong with that request. Please try again.