var own = {}.hasOwnProperty;
function zwitch(t, n) {
	let r = n || {};
	function i(n, ...r) {
		let a = i.invalid, o = i.handlers;
		if (n && own.call(n, t)) {
			let r = String(n[t]);
			a = own.call(o, r) ? o[r] : i.unknown;
		}
		if (a) return a.call(this, n, ...r);
	}
	return i.handlers = r.handlers || {}, i.invalid = r.invalid, i.unknown = r.unknown, i;
}
export { zwitch };
