rewrite rules: analysis: attributes can define variables in match, but not in rhs