Skip to content

Instantly share code, notes, and snippets.

@bduggan
Last active May 25, 2016 18:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bduggan/f24e0d9a70fc7c8430ca7b30ab8517c2 to your computer and use it in GitHub Desktop.
Save bduggan/f24e0d9a70fc7c8430ca7b30ab8517c2 to your computer and use it in GitHub Desktop.
class X {
has Date(Str) $.day;
}
my $x = X.new(:day<2012-01-01>);
===SORRY!=== Error while compiling /home/bduggan/perl6/day.p6
Coercion Date(Str) is insufficiently type-like to qualify a variable
at /home/bduggan/perl6/day.p6:2
------> has Date(Str) $.day⏏
expecting any of:
constraint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment