ALL and MATCH pattern matching callback