projects
/
gitmo/Moose.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
9b6e6cf83d6e96e9ac1d1be14113304b1c000dc6
[gitmo/Moose.git]
/
benchmarks
/
cmop
/
lib
/
MOP
/
Installed
/
Point.pm
1
2
use lib reverse @INC;
3
4
package MOP::Installed::Point;
5
6
use strict;
7
use warnings;
8
use metaclass;
9
10
__PACKAGE__->meta->add_attribute('x' => (accessor => 'x', default => 10));
11
__PACKAGE__->meta->add_attribute('y' => (accessor => 'y'));
12
13
sub new {
14
my $class = shift;
15
$class->meta->new_object(@_);
16
}
17
18
sub clear {
19
my $self = shift;
20
$self->x(0);
21
$self->y(0);
22
}
23
24
1;
25
26
__END__