patmatch1.spad line 195 [edit on github]
This package provides pattern matching functions on symbols.
patternMatch(expr, pat, res) matches the pattern pat to the expression expr; res contains the variables of pat which are already matched and their matches (necessary for recursion).