Skip to content

Instantly share code, notes, and snippets.

@TimToady
Created September 19, 2015 16:20
Show Gist options
  • Save TimToady/003e9c5c953de6014864 to your computer and use it in GitHub Desktop.
Save TimToady/003e9c5c953de6014864 to your computer and use it in GitHub Desktop.
proto sub infix:<foo>(|) is pure { * }
multi sub infix:<foo>(**@args is raw) { @args.minmax }
proto sub infix:<bar>(|) is pure { * }
multi sub infix:<bar>(+args) { args.minmax }
proto sub infix:<baz>(|) is pure { * }
multi sub infix:<baz>(+args) { 42; args.minmax }
my @a = 1,2,3,4;
my @b = 5,6,7,8;
say @a foo @b;
say @a bar @b;
say @a baz @b;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment