Substituted type template parameters should hold the original parameter
and the canonical type that was used for instantiation. We were missing
a canonicalization step and some extra sugar would have leaked through
into the instantiation.
Test case reduced from PR19372. It could use improvement if anyone has a
better idea for how to inject type sugar into this codepath.