diff options
author | Alessandro Ranellucci <aar@cpan.org> | 2011-09-06 13:50:43 +0400 |
---|---|---|
committer | Alessandro Ranellucci <aar@cpan.org> | 2011-09-06 13:50:43 +0400 |
commit | 26b05ab155046c4c04fc326aa6d9d00ffc799270 (patch) | |
tree | 918c35f4f83dbd9dd01219166e6e6d8c6ed6252f /lib/Slic3r/Line.pm | |
parent | bf5824781da6d5cf766b4e6da6ba66f4748e4243 (diff) |
Replaced Moose with Moo => big performance boost and easier packaging
Diffstat (limited to 'lib/Slic3r/Line.pm')
-rw-r--r-- | lib/Slic3r/Line.pm | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/lib/Slic3r/Line.pm b/lib/Slic3r/Line.pm index 2cdead36b..0919a06a9 100644 --- a/lib/Slic3r/Line.pm +++ b/lib/Slic3r/Line.pm @@ -1,32 +1,28 @@ package Slic3r::Line; -use Moose; -use Moose::Util::TypeConstraints; +use Moo; use Scalar::Util qw(weaken); -subtype 'Slic3r::Line::Length', as 'Int'; -coerce 'Slic3r::Line::Length', from 'Num', via { sprintf '%.0f', $_ }; - has 'a' => ( is => 'ro', - isa => 'Slic3r::Point', + #isa => 'Slic3r::Point', required => 1, ); has 'b' => ( is => 'ro', - isa => 'Slic3r::Point', + #isa => 'Slic3r::Point', required => 1, ); has 'polyline' => ( is => 'rw', - isa => 'Slic3r::Polyline', + #isa => 'Slic3r::Polyline', weak_ref => 1, ); has 'solid_side' => ( is => 'rw', - isa => enum([qw(left right)]), # going from a to b + #isa => enum([qw(left right)]), # going from a to b ); sub BUILD { |