Move subst data structures into subst.rs, fix capitalization
Simplify MonoId not to include parameters which, given coherence, are purely derived
Move Def out of syntax crate, where it does not belong
Stop passing around Option<&substs> in trans and just pass &substs, making the code more regular
Add missing test case for contravariant trait matching
Fix resolve to not permit refs to type vars from outer fns
(Fixes #14603)
auto merge of #14702 : nikomatsakis/rust/issue-5527-namespace-substs-b, r=pnkfelix

Separate out initial refactorings for PR #14604