(typenames, types)
| 1566 | } |
| 1567 | |
| 1568 | function parseTypenames$1(typenames, types) { |
| 1569 | return typenames.trim().split(/^|\s+/).map(function(t) { |
| 1570 | var name = "", i = t.indexOf("."); |
| 1571 | if (i >= 0) name = t.slice(i + 1), t = t.slice(0, i); |
| 1572 | if (t && !types.hasOwnProperty(t)) throw new Error("unknown type: " + t); |
| 1573 | return {type: t, name: name}; |
| 1574 | }); |
| 1575 | } |
| 1576 | |
| 1577 | Dispatch.prototype = dispatch.prototype = { |
| 1578 | constructor: Dispatch, |