allow casting Typedef to another Typedef

Now when I tries to cast from `Typedef!(Foo)` to `Typedef!(const(Foo))` I get a `e2ir` error.
Moreover, when I have a `alias TD = Typedef(Foo)`, I can't cast `const(TD)` to `TD`.
This PR fixes this issue.
What's the point of just repeating the signature constrain in an empty static if?