An interpreter for pattern matching expressions