Skip to content

Instantly share code, notes, and snippets.

@rakudo
Created July 27, 2009 23:05
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save rakudo/156813 to your computer and use it in GitHub Desktop.
pmichaud@plum:~/rakudo$ make t/spec/S06-multi/type-based.t
ok 1 - dispatched to the Str sub
ok 2 - dispatched to the Int sub
ok 3 - dispatched to the Num sub
ok 4 - dispatched to the Bool sub
ok 5 - dispatched to the Rule sub
ok 6 - dispatched to the Sub sub
ok 7 - dispatched to the Array sub
ok 8 - dispatched to the Hash sub
ok 9 - dispatched to the IO sub
ok 10 - omitting 'sub' when declaring 'multi sub's works (1)
ok 11 - omitting 'sub' when declaring 'multi sub's works (2)
ok 12 - Slurpy MMD to nullary
ok 13 - Slurpy MMD to listop via args
ok 14 - Slurpy MMD to listop via list
ok 15 - Sigil-based dispatch (Any)
ok 16 - Sigil-based dispatch (Callable)
ok 17 - Sigil-based dispatch (Arrays)
ok 18 - Sigil-based dispatch (Associative)
ok 19 - Basic sanity
ok 20 - multi dispatch with ::T generics
ok 21 - fallback if there is a ::T variant
ok 22 - Basic sanity 2
ok 23 - multi dispatch with faked generics
ok 24 - fallback if there is a faked generic
ok 25 - subset types involving mulitple parameters (fallback)
ok 26 - subset types involving mulitple parameters (success)
ok 27 - arity-based dispatch to ($)
ok 28 - arity-based dispatch to ($, $)
ok 29 - arity-based dispatch to ($, $, $)
ok 30 - arity-based dispatch to ($, $, @)
ok 31 - can dispatch to "$ where 0"
ok 32 - ... and the ordinary dispatch still works
ok 33 - can dispatch on typed Hash (Int)
ok 34 - can dispatch on typed Hash (Str)
ok 35 - can dispatch on typed Hash (Array)
ok 36 - can dispatch on typed Array (Int)
ok 37 - can dispatch on typed Array (Str)
ok 38 - can dispatch on typed Array (Array)
ok 39 - multis in classes (1)
ok 40 - multis in classes (2)
ok 41 - multis in classes (3)
ok 42 - where-clause that uses multiple params (1)
ok 43 - where-clause that uses multiple params (1)
ok 44 - generics in multis (+)
ok 45 - generics in multis (-)
ok
All tests successful.
Files=1, Tests=45, 9 wallclock secs ( 0.03 usr 0.00 sys + 8.99 cusr 0.15 csys = 9.17 CPU)
Result: PASS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment