Rewrite primop transform functions

I removed match_fail_arg/1 because I didn't like its type and introduced
primop/2 which calls match_fail_primop/2 if the primop name is
match_fail.
Transform calls to `erlang:apply(badrecord)`