From: Stevan Little Date: Wed, 19 Apr 2006 20:06:32 +0000 (+0000) Subject: anon-classes X-Git-Tag: 0_26~13 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=4d154c08ac55b0f2daa5c6371f6542214e53a51b;hp=c3e7c446227eef2b683e872dd6e8cecfcf5e81a6;p=gitmo%2FClass-MOP.git anon-classes --- diff --git a/lib/Class/MOP/Class.pm b/lib/Class/MOP/Class.pm index 3ddbbae..cdece7e 100644 --- a/lib/Class/MOP/Class.pm +++ b/lib/Class/MOP/Class.pm @@ -135,7 +135,12 @@ sub create { } { + # NOTE: + # this should be sufficient, if you have a + # use case where it is not, write a test and + # I will change it. my $ANON_CLASS_SERIAL = 0; + sub create_anon_class { my ($class, %options) = @_; my $package_name = 'Class::MOP::Class::__ANON__::SERIAL::' . ++$ANON_CLASS_SERIAL;