Skip to content

Instantly share code, notes, and snippets.

@Whateverable
Created December 9, 2019 09:08
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 Whateverable/e0f1d421005933f671e738508398a9be to your computer and use it in GitHub Desktop.
Save Whateverable/e0f1d421005933f671e738508398a9be to your computer and use it in GitHub Desktop.
evalable6
role R[Str:D $_n]{our Str:D $n = $_n};role R2[Str:D $n]{also does R[$n]};class A does R2['asd'] {};say A.n
(exit code 1)
===SORRY!=== Error while compiling /tmp/bCguttjt2y
Cannot put a type constraint on an 'our'-scoped variable
at /tmp/bCguttjt2y:1
------> role R[Str:D $_n]{our Str:D $n⏏ = $_n};role R2[Str:D $n]{also does R[$n
expecting any of:
constraint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment