This is an automated email from the git hooks/post-receive script.

gregoa pushed a commit to annotated tag release-0.013
in repository libclass-tiny-perl.

commit 7684d73eb4b75e1c0c5be6db49545d72f15a33da
Author: David Golden <>
Date:   Tue Nov 26 11:33:57 2013 -0500

    expanded comparison to Object::Tiny and Class::Accessor
 Changes           |  4 ++++
 lib/Class/ | 33 +++++++++++++++++++++++++++------
 2 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/Changes b/Changes
index 1b716f8..dad5cce 100644
--- a/Changes
+++ b/Changes
@@ -2,6 +2,10 @@ Revision history for Class-Tiny
+    - expanded comparision to Object::Tiny and Class::Accessor
 0.012     2013-11-01 16:36:35 America/New_York
diff --git a/lib/Class/ b/lib/Class/
index 8354c58..61d0a83 100644
--- a/lib/Class/
+++ b/lib/Class/
@@ -249,7 +249,7 @@ set.  The object is passed as an argument to a code 
     use Class::Tiny qw/name id/, {
         title     => 'Peon',
         skills    => sub { [] },
-        hire_date => sub { $_[0]->_build_hire_date }, 
+        hire_date => sub { $_[0]->_build_hire_date },
 When subclassing, if multiple accessors of the same name exist in different
@@ -407,10 +407,31 @@ L<Object::Tiny> and L<Object::Tiny::RW> were close to 
what I wanted, but
 lacking some features I deemed necessary, and their maintainers have an even
 more strict philosophy against feature creep than I have.
-I looked for something like it on CPAN, but after checking a dozen class
-creators I realized I could implement it exactly how I wanted faster than I
-could search CPAN for something merely sufficient.  Compared to everything
-else, this is smaller in implementation and simpler in API.
+I also considered L<Class::Accessor>, which has been around a long time and is
+heavily used, but it, too, lacked features I wanted and did things in ways I
+considered poor design.
+I looked for something else on CPAN, but after checking a dozen class creators
+I realized I could implement exactly what I wanted faster than I could search
+CPAN for something merely sufficient.
+In general, compared to most things on CPAN (other than Object::Tiny),
+Class::Tiny is smaller in implementation and simpler in API.
+Specifically, here is how Class::Tiny ("C::T") compares to Object::Tiny
+("O::T") and Class::Accessor ("C::A"):
+ FEATURE                            C::T    O::T      C::A
+ --------------------------------------------------------------
+ attributes defined via import      yes     yes       no
+ read/write accessors               yes     no        yes
+ lazy attribute defaults            yes     no        no
+ provides new                       yes     yes       yes
+ provides DESTROY                   yes     no        no
+ new takes either hashref or list   yes     no (list) no (hash)
+ new validates arguments            yes     no        no
+ Moo(se)-like BUILD/DEMOLISH        yes     no        no
+ no extraneous methods via @ISA     yes     yes       no
 =head2 Why this instead of Moose or Moo?
@@ -424,7 +445,7 @@ required.
 By contrast, Class::Tiny has no MOP and has B<zero> non-core dependencies for
 Perls in the L<support window|perlpolicy>.  It has far less code, less
 complexity and no learning curve. If you don't need or can't afford what Moo or
-Moose offer, this is a intended to be a reasonable fallback.
+Moose offer, this is intended to be a reasonable fallback.
 That said, Class::Tiny offers Moose-like conventions for things like C<BUILD>
 and C<DEMOLISH> for some minimal interoperability and an easier upgrade path.

Alioth's /usr/local/bin/git-commit-notice on 

Pkg-perl-cvs-commits mailing list

Reply via email to