pervasive type constraints
[scpubgit/DX.git] / lib / DX / Class.pm
1 package DX::Class;
2
3 use Import::Into;
4
5 sub import {
6   strictures->import::into({ level => 1, version => 2 }); # should pass version
7   DX::Types->import::into(1, ':types', ':assert');
8   DX::Utils->import::into(1, '*trace');
9   Types::Standard->import::into(
10     1, qw(Maybe ArrayRef HashRef Str Num Int Enum Bool)
11   );
12   Try::Tiny->import::into(1);
13   Moo->import::into(1);
14   # This would not be safe with method modifiers, but since the role
15   # provides only a single method it works out fine.
16   caller()->can('with')->('DX::Role::But');
17 }
18
19 1;