From: Shawn M Moore Date: Tue, 24 Mar 2009 03:11:42 +0000 (-0400) Subject: Use blessed instead of ref to get an instance's class name X-Git-Tag: 0.78_02~4 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=68af25373a1c1e2200da61ee5c5bd3a0df3887c5;p=gitmo%2FClass-MOP.git Use blessed instead of ref to get an instance's class name --- diff --git a/lib/Class/MOP/Class.pm b/lib/Class/MOP/Class.pm index 7a6f039..4b0112a 100644 --- a/lib/Class/MOP/Class.pm +++ b/lib/Class/MOP/Class.pm @@ -411,7 +411,7 @@ sub rebless_instance { $old_metaclass = $instance->meta; } else { - $old_metaclass = $self->initialize(ref($instance)); + $old_metaclass = $self->initialize(blessed($instance)); } my $meta_instance = $self->get_meta_instance();