Improve code reuse between trans/_match.rs and check_match.rs

I believe there's more commonality to be found there but maybe small steps are better. I'm also in the process of documenting what I can, I will see if I can add it to this PR.

It also seems to me that ideally some of this stuff (especially the pattern sanity check) could live as a separate compiler-agnostic module but I understand this may not be the right time (if not the worst) to start the process of modularising rustc.
The comment above this code, with the transcribed dialogue, needs an addendum just to point out how the interface to `enter_match` has slightly changed.  (It now takes a callback that accepts a vec of patterns rather than one, and it is non-obvious to someone reading this comment out of context, or at least to me, how to translate niko's statement "it is provided with a function that tests each pattern to see if it might possibly apply and so forth")