projects
/
gitmo/Class-MOP.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
(parent:
051a2fc
)
Make class_of actually work, since it's not a method! :x
Shawn M Moore [Sat, 28 Mar 2009 19:54:20 +0000 (15:54 -0400)]
lib/Class/MOP.pm
patch
|
blob
|
blame
|
history
diff --git
a/lib/Class/MOP.pm
b/lib/Class/MOP.pm
index
e99cc24
..
97e326c
100644
(file)
--- a/
lib/Class/MOP.pm
+++ b/
lib/Class/MOP.pm
@@
-137,13
+137,9
@@
sub _is_valid_class_name {
}
sub class_of {
- my $self = shift;
- my $class = shift;
+ my $class = blessed($_[0]) || $_[0];
return undef if !defined($class);
-
- $class = blessed($class) || $class;
-
return get_metaclass_by_name($class);
}