X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=examples%2FInsideOutClass.pod;h=5ea7e788364f65a42858aecb6b612387d99971e1;hb=c9e77dbb017258dc44295fc4ec8e0bdd99ec9361;hp=781370e95d42eb2b308d0390f6b368abef792211;hpb=677eb1584b6e27c6079daed35110cb4192153db4;p=gitmo%2FClass-MOP.git diff --git a/examples/InsideOutClass.pod b/examples/InsideOutClass.pod index 781370e..5ea7e78 100644 --- a/examples/InsideOutClass.pod +++ b/examples/InsideOutClass.pod @@ -16,7 +16,7 @@ sub construct_instance { # create a scalar ref to use as # the inside-out instance my $instance = \(my $var); - foreach my $attr (map { $_->{attribute} } $class->compute_all_applicable_attributes()) { + foreach my $attr ($class->compute_all_applicable_attributes()) { # if the attr has an init_arg, use that, otherwise, # use the attributes name itself as the init_arg my $init_arg = $attr->has_init_arg() ? $attr->init_arg() : $attr->name;