dispatch now supports matching by predicate and value-comparison, in addition to type.