1 package DX::Predicate::Dict;
3 use DX::Utils qw(step dict TYPE_OF);
6 with 'DX::Role::Predicate';
8 sub _possible_resolution_list {
9 my ($self, $arg, $proto) = @_;
11 die "dict called with non-dict"
12 unless $arg->isa('DX::Value::Dict');
15 depends_on => [ [ undef ,=> [ TYPE_OF ,=> $arg ] ] ]
18 if ($proto and not $proto->isa('DX::Value::Dict')) {
19 die "dict called with non-dict prototype";
21 my $set = $arg->action_for_set_value($proto||dict());
24 depends_on => [ [ undef ,=> [ TYPE_OF ,=> $arg ] ] ]