r44674 - in /trunk/libclass-mop-perl: ./ debian/ lib/ lib/Class/ lib/Class/MOP/ lib/Class/MOP/Class/Immutable/ lib/Class/MOP/Method/ t/
jawnsy-guest at users.alioth.debian.org
jawnsy-guest at users.alioth.debian.org
Wed Sep 23 15:19:39 UTC 2009
Author: jawnsy-guest
Date: Wed Sep 23 15:19:33 2009
New Revision: 44674
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=44674
Log:
WAITS FOR libmoose-perl 0.90 -- breaks older versions
* New upstream release
+ Adds set_raw_value and get_raw_value, side effect free variants
of {get,set}_value
* Add Breaks: libmoose-perl << 0.90
Modified:
trunk/libclass-mop-perl/Changes
trunk/libclass-mop-perl/META.yml
trunk/libclass-mop-perl/README
trunk/libclass-mop-perl/debian/changelog
trunk/libclass-mop-perl/debian/control
trunk/libclass-mop-perl/lib/Class/MOP.pm
trunk/libclass-mop-perl/lib/Class/MOP/Attribute.pm
trunk/libclass-mop-perl/lib/Class/MOP/Class.pm
trunk/libclass-mop-perl/lib/Class/MOP/Class/Immutable/Trait.pm
trunk/libclass-mop-perl/lib/Class/MOP/Deprecated.pm
trunk/libclass-mop-perl/lib/Class/MOP/Instance.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method/Accessor.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method/Constructor.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method/Generated.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method/Inlined.pm
trunk/libclass-mop-perl/lib/Class/MOP/Method/Wrapped.pm
trunk/libclass-mop-perl/lib/Class/MOP/Module.pm
trunk/libclass-mop-perl/lib/Class/MOP/Object.pm
trunk/libclass-mop-perl/lib/Class/MOP/Package.pm
trunk/libclass-mop-perl/lib/metaclass.pm
trunk/libclass-mop-perl/t/014_attribute_introspection.t
Modified: trunk/libclass-mop-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/Changes?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/Changes (original)
+++ trunk/libclass-mop-perl/Changes Wed Sep 23 15:19:33 2009
@@ -1,4 +1,11 @@
Revision history for Perl extension Class-MOP.
+
+0.94 Tue, Sep 22, 2009
+ * Class::MOP::Attribute
+ - Introduce set_raw_value and get_raw_value, side effect free variants
+ of {get,set}_value. These don't do anything useful in Class::MOP but
+ have different behavior that set_value and get_value for Moose
+ attributes. (nothingmuch)
0.93 Tue, Sep 15, 2009
* Class::MOP
Modified: trunk/libclass-mop-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/META.yml?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/META.yml (original)
+++ trunk/libclass-mop-perl/META.yml Wed Sep 23 15:19:33 2009
@@ -32,4 +32,4 @@
perl: 5.8.1
resources:
license: http://dev.perl.org/licenses/
-version: 0.93
+version: 0.94
Modified: trunk/libclass-mop-perl/README
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/README?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/README (original)
+++ trunk/libclass-mop-perl/README Wed Sep 23 15:19:33 2009
@@ -1,4 +1,4 @@
-Class::MOP version 0.93
+Class::MOP version 0.94
===========================
See the individual module documentation for more information
Modified: trunk/libclass-mop-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/debian/changelog?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/debian/changelog (original)
+++ trunk/libclass-mop-perl/debian/changelog Wed Sep 23 15:19:33 2009
@@ -1,6 +1,12 @@
-libclass-mop-perl (0.93-1) UNRELEASED; urgency=low
-
- WAITS FOR libmoose-perl (>= 0.90): breaks older version
+libclass-mop-perl (0.94-1) UNRELEASED; urgency=low
+
+ WAITS FOR libmoose-perl 0.90 -- breaks older versions
+
+ [ Jonathan Yu ]
+ * New upstream release
+ + Adds set_raw_value and get_raw_value, side effect free variants
+ of {get,set}_value
+ * Add Breaks: libmoose-perl << 0.90
[ Ryan Niebur ]
* Update jawnsy's email address
@@ -13,7 +19,7 @@
version more recent than 5.8.0.
* Bump Standards-Version to 3.8.3.
- -- Ansgar Burchardt <ansgar at 43-1.org> Thu, 17 Sep 2009 22:11:14 +0200
+ -- Jonathan Yu <jawnsy at cpan.org> Wed, 23 Sep 2009 07:10:12 -0400
libclass-mop-perl (0.92-1) unstable; urgency=low
Modified: trunk/libclass-mop-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/debian/control?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/debian/control (original)
+++ trunk/libclass-mop-perl/debian/control Wed Sep 23 15:19:33 2009
@@ -25,7 +25,7 @@
libdevel-globaldestruction-perl, libsub-name-perl (>= 0.04),
libmro-compat-perl
Suggests: libmoose-perl
-Breaks: libmoose-perl (<< 0.86)
+Breaks: libmoose-perl (<< 0.90)
Description: Perl module implementing a Meta Object Protocol (MOP)
Class::MOP is an implementation of a Meta Object Protocol for the Perl object
system. It does not change the behavior or characteristics of the classic Perl
Modified: trunk/libclass-mop-perl/lib/Class/MOP.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP.pm Wed Sep 23 15:19:33 2009
@@ -24,7 +24,7 @@
*check_package_cache_flag = \&mro::get_pkg_gen;
}
-our $VERSION = '0.93';
+our $VERSION = '0.94';
our $XS_VERSION = $VERSION;
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Attribute.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Attribute.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Attribute.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Attribute.pm Wed Sep 23 15:19:33 2009
@@ -9,7 +9,7 @@
use Carp 'confess';
use Scalar::Util 'blessed', 'weaken';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
@@ -305,7 +305,10 @@
);
}
-sub set_value {
+sub set_value { shift->set_raw_value(@_) }
+sub get_value { shift->get_raw_value(@_) }
+
+sub set_raw_value {
my ($self, $instance, $value) = @_;
Class::MOP::Class->initialize(ref($instance))
@@ -313,7 +316,7 @@
->set_slot_value($instance, $self->name, $value);
}
-sub get_value {
+sub get_raw_value {
my ($self, $instance) = @_;
Class::MOP::Class->initialize(ref($instance))
@@ -827,6 +830,12 @@
Sets the value without going through the accessor. Note that this
works even with read-only attributes.
+=item B<< $attr->set_raw_value($instance, $value) >>
+
+Sets the value with no side effects such as a trigger.
+
+This doesn't actually apply to Class::MOP attributes, only to subclasses.
+
=item B<< $attr->set_initial_value($instance, $value) >>
Sets the value without going through the accessor. This method is only
@@ -836,6 +845,12 @@
Returns the value without going through the accessor. Note that this
works even with write-only accessors.
+
+=item B<< $sttr->get_raw_value($instance) >>
+
+Returns the value without any side effects such as lazy attributes.
+
+Doesn't actually apply to Class::MOP attributes, only to subclasses.
=item B<< $attr->has_value($instance) >>
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Class.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Class.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Class.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Class.pm Wed Sep 23 15:19:33 2009
@@ -14,7 +14,7 @@
use Sub::Name 'subname';
use Devel::GlobalDestruction 'in_global_destruction';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
@@ -1163,7 +1163,7 @@
The Class Protocol is the largest and most complex part of the
Class::MOP meta-object protocol. It controls the introspection and
manipulation of Perl 5 classes, and it can create them as well. The
-best way to understand what this module can do, is to read the
+best way to understand what this module can do is to read the
documentation for each of its methods.
=head1 INHERITANCE
@@ -1175,7 +1175,7 @@
=head2 Class construction
These methods all create new C<Class::MOP::Class> objects. These
-objects can represent existing classes, or they can be used to create
+objects can represent existing classes or they can be used to create
new classes from scratch.
The metaclass object for a given class is a singleton. If you attempt
@@ -1187,7 +1187,7 @@
=item B<< Class::MOP::Class->create($package_name, %options) >>
This method creates a new C<Class::MOP::Class> object with the given
-package name. It accepts a number of options.
+package name. It accepts a number of options:
=over 8
@@ -1206,7 +1206,7 @@
=item * methods
An optional hash reference of methods for the class. The keys of the
-hash reference are method names, and values are subroutine references.
+hash reference are method names and values are subroutine references.
=item * attributes
@@ -1231,7 +1231,7 @@
metaclass object, which prevents the metaclass from going out of scope
while any instances exist.
-This only works if the instance if based on a hash reference, however.
+This only works if the instance is based on a hash reference, however.
=item B<< Class::MOP::Class->initialize($package_name, %options) >>
@@ -1301,12 +1301,11 @@
instance's attributes. A special C<__INSTANCE__> key can be passed to
provide an already generated instance, rather than having Class::MOP
generate it for you. This is mostly useful for using Class::MOP with
-foreign classes, which generally generate instances using their own
-constructor.
+foreign classes which generate instances using their own constructors.
=item B<< $metaclass->instance_metaclass >>
-Returns the class name of the instance metaclass, see
+Returns the class name of the instance metaclass. See
L<Class::MOP::Instance> for more information on the instance
metaclass.
@@ -1468,7 +1467,7 @@
This will return a L<Class::MOP::Attribute> for the specified
C<$attribute_name>. If the class does not have the specified
-attribute, it returns C<undef>
+attribute, it returns C<undef>.
Unlike C<get_attribute>, this attribute I<will> look for the named
attribute in superclasses.
@@ -1476,7 +1475,7 @@
=item B<< $metaclass->add_attribute(...) >>
This method accepts either an existing L<Class::MOP::Attribute>
-object, or parameters suitable for passing to that class's C<new>
+object or parameters suitable for passing to that class's C<new>
method.
The attribute provided will be added to the class.
@@ -1516,8 +1515,8 @@
object itself.
After immutabilization, the metaclass object will cache most informational
-methods that returns information about methods or attributes.. Methods which
-would alter the class, such as C<add_attribute>, C<add_method>, and so on will
+methods that returns information about methods or attributes. Methods which
+would alter the class, such as C<add_attribute> and C<add_method>, will
throw an error on an immutable metaclass object.
The immutabilization system in L<Moose> takes much greater advantage
@@ -1527,7 +1526,7 @@
=item B<< $metaclass->make_immutable(%options) >>
-This method will create an immutable transformer and uses it to make
+This method will create an immutable transformer and use it to make
the class and its metaclass object immutable.
This method accepts the following options:
@@ -1600,7 +1599,7 @@
Method modifiers are hooks which allow a method to be wrapped with
I<before>, I<after> and I<around> method modifiers. Every time a
-method is called, it's modifiers are also called.
+method is called, its modifiers are also called.
A class can modify its own methods, as well as methods defined in
parent classes.
@@ -1644,9 +1643,9 @@
Of course there is a performance cost associated with method
modifiers, but we have made every effort to make that cost directly
-proportional to the number of modifier features you utilize.
-
-The wrapping method does it's best to B<only> do as much work as it
+proportional to the number of modifier features you use.
+
+The wrapping method does its best to B<only> do as much work as it
absolutely needs to. In order to do this we have moved some of the
performance costs to set-up time, where they are easier to amortize.
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Class/Immutable/Trait.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Class/Immutable/Trait.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Class/Immutable/Trait.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Class/Immutable/Trait.pm Wed Sep 23 15:19:33 2009
@@ -8,7 +8,7 @@
use Carp 'confess';
use Scalar::Util 'blessed', 'weaken';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Deprecated.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Deprecated.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Deprecated.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Deprecated.pm Wed Sep 23 15:19:33 2009
@@ -6,7 +6,7 @@
use Carp qw( cluck );
use Scalar::Util qw( blessed );
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Instance.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Instance.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Instance.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Instance.pm Wed Sep 23 15:19:33 2009
@@ -6,7 +6,7 @@
use Scalar::Util 'weaken', 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'weaken', 'reftype', 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method/Accessor.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method/Accessor.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method/Accessor.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method/Accessor.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'blessed', 'weaken';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method/Constructor.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method/Constructor.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method/Constructor.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method/Constructor.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'blessed', 'weaken', 'looks_like_number';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method/Generated.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method/Generated.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method/Generated.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method/Generated.pm Wed Sep 23 15:19:33 2009
@@ -6,7 +6,7 @@
use Carp 'confess';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method/Inlined.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method/Inlined.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method/Inlined.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method/Inlined.pm Wed Sep 23 15:19:33 2009
@@ -6,7 +6,7 @@
use Carp 'confess';
use Scalar::Util 'blessed', 'weaken', 'looks_like_number', 'refaddr';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Method/Wrapped.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Method/Wrapped.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Method/Wrapped.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Method/Wrapped.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Module.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Module.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Module.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Module.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Object.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Object.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Object.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Object.pm Wed Sep 23 15:19:33 2009
@@ -6,7 +6,7 @@
use Scalar::Util 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/Class/MOP/Package.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/Class/MOP/Package.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/Class/MOP/Package.pm (original)
+++ trunk/libclass-mop-perl/lib/Class/MOP/Package.pm Wed Sep 23 15:19:33 2009
@@ -8,7 +8,7 @@
use Carp 'confess';
use Sub::Name 'subname';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/lib/metaclass.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/lib/metaclass.pm?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/lib/metaclass.pm (original)
+++ trunk/libclass-mop-perl/lib/metaclass.pm Wed Sep 23 15:19:33 2009
@@ -7,7 +7,7 @@
use Carp 'confess';
use Scalar::Util 'blessed';
-our $VERSION = '0.93';
+our $VERSION = '0.94';
$VERSION = eval $VERSION;
our $AUTHORITY = 'cpan:STEVAN';
Modified: trunk/libclass-mop-perl/t/014_attribute_introspection.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libclass-mop-perl/t/014_attribute_introspection.t?rev=44674&op=diff
==============================================================================
--- trunk/libclass-mop-perl/t/014_attribute_introspection.t (original)
+++ trunk/libclass-mop-perl/t/014_attribute_introspection.t Wed Sep 23 15:19:33 2009
@@ -1,7 +1,7 @@
use strict;
use warnings;
-use Test::More tests => 69;
+use Test::More tests => 71;
use Test::Exception;
use Class::MOP;
@@ -41,6 +41,8 @@
slots
get_value
set_value
+ get_raw_value
+ set_raw_value
set_initial_value
has_value
clear_value
More information about the Pkg-perl-cvs-commits
mailing list