has re =>(is => 'rw', isa =>'RegexpRef', default => '')
In BUILD I specified$self->re(qr/^[0-9]+$/); (gave a contraint error; OK, no reference)
Then I tried
my $rx = qr/^[0-9]+$/; $self->re(\$rx); # or $self->re(\qr/^[0-9]+$/);
Both also resulted in a constraint error.
How should I use RegexpRef?
Thanks for your help.
In reply to Moose RegexpRef by kdjantzen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |