Use terminals instead of patterns