name-based pattern matching for most of the AST classes

unfortunately we can't turn everything into name-based until SI-9029 is fixed