The patterns must correspond to language syntax categories; in this case, both patterns must be of syntax category statement also separated in sympathy with the patterns by ->.
The patterns must match language syntactic categories; in this case, both patterns need to be of syntax category statement also separated by -> according to the patterns.