jonathan worthington jonathanjnthnnet larry wall wrote tue aug 05 2008 061730pm 0200 jonathan worthington wrote hi currently reviewing bits spec surrounding multiple dispatch course question two ill probably later dust settles head 1 spec says proto also adds implicit multi routines short name within scope unless explicit modifier write proto sub foothing sub fooint x sub foo give kind error youve declared something clearly cant one also proto id consider error ok sounds sane 2 write multi sub fooint blah 1 proto sub fooblah thingy 2 multi sub foo 3 1 get thingy trait declared proto im clear 3 gets think proto expected work retroactively fact think probably error declare proto nonproto scope ok error also seems sane 3 spec says parameter list may one double semicolon parameters never considered multiple dispatch except course still veto number types mismatch veto take place multiple dispatch given us candidate try bind parameters signature part multiple dispatch example supposing declare multi fooint num b 1 multi fooint str b 2 multi fooint num b num c 3 happens foo2 randomthingnew ambiguous dispatch error foo2 25 ambiguous dispatch error 1 2 vetos foo1 25 34 ambiguous dispatch error 3 one arity match basically im getting multimethods ambiguous long name binding fails doesnt make us return multiple dispatch algorithm im kinda expecting would mean every one fails want check meant wording believe veto giving wrong idea something happens fact whats term allowing acceptable candidates put names ballot im sure since carving set possible candidates dispatcher sees could bind maybe go gerrymandering anyway tsa surmises ballot vetted stacked advanceonly candidates could bind considered part candidate set ok would seem mean looking could bind also check arity type constraints nonmmd parameters c dispatch examples wed get foo2 randomthingnew matching candidates error foo2 25 1 candidate get foo1 25 34 3 candidate get abstract candidates match never get names ballot though course implementation might choose determine lazily long preserves semantics im thinking mine bit lazily least first cut alternately even list valid candidates determined eagerly candidate list construction memoized based typeshape capture generally redone see different typeshape meaning different may depend specific signatures particular whether signatures rely subset constraints including individual values degenerate subsets nod sounds like starting wonder road optimizations though id rather something simple correct first least theres large enough body tests sure optimizations arent making us get wrong answers really quickly thanks jonathan wed 06 aug 2008 163338 0200 multiple dispatch questions