Reimplement type substitutions using IntMap instead of Map.
Reimplement type substitutions using IntMap instead of Map.

This speeds up the test suite by about 10%, and makes the example
file from issue #544 typecheck about 7x faster.

GaloisInc/cryptol,GaloisInc/cryptol,GaloisInc/cryptol