Paste2 Logo
  1. $ parrot perl6.pbc
  2. > rule Foo { (\d+) }
  3. > "1234 x" ~~ Foo; say $/;
  4. 1234
  5. > "1234 x" ~~ Foo; say @($/);
  6. 1234
  7. > "1234 x" ~~ Foo; say @($/).WHAT;
  8. List
  9. > "1234 x" ~~ Foo; say @($/).elems;
  10. Method 'elems' not found for invocant of class 'ResizablePMCArray'
  11. > # wtf?!
  12. > say [1,2,3,4].elems
  13. 4
  14. > say <1 2 3 4>.elems
  15. 4
  16. $

I can't take the length of a List of positional captures, because internals are poking out of the Match.