From: Matt S Trout Date: Sat, 21 Jul 2012 19:57:29 +0000 (+0000) Subject: I'm an idiot X-Git-Tag: v1.000002~7 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo%2FMoo.git;a=commitdiff_plain;h=3b4a915aed3f637f76730b52206681aa7e3503cf I'm an idiot --- diff --git a/Changes b/Changes index ceebff1..12ff01c 100644 --- a/Changes +++ b/Changes @@ -1,3 +1,5 @@ + - fix stupid typo in new Sub::Quote section + 1.000001 - 2012-07-21 - documentation tweaks and cleanup - ignore required when default or builder is present diff --git a/lib/Moo.pm b/lib/Moo.pm index e651d39..43f826d 100644 --- a/lib/Moo.pm +++ b/lib/Moo.pm @@ -629,7 +629,8 @@ To do this, you can write use Sub::Quote; has foo => ( - is => quote_sub(q{ die "Not <3" unless $_[0] < 3 }) + is => 'ro', + isa => quote_sub(q{ die "Not <3" unless $_[0] < 3 }) ); which will be inlined as @@ -642,7 +643,8 @@ which will be inlined as or to avoid localizing @_, has foo => ( - is => quote_sub(q{ my ($val) = @_; die "Not <3" unless $val < 3 }) + is => 'ro', + isa => quote_sub(q{ my ($val) = @_; die "Not <3" unless $val < 3 }) ); which will be inlined as