Implement ordering comparisons for type-level naturals and symbols.
authorIavor S. Diatchki <diatchki@galois.com>
Wed, 19 Mar 2014 01:54:23 +0000 (18:54 -0700)
committerIavor S. Diatchki <diatchki@galois.com>
Wed, 19 Mar 2014 01:54:23 +0000 (18:54 -0700)
commit5e4bdb5fc5e741522cbb787731422da3f12aa398
tree3562d77379b7cd4e74f4586b9d9a07e65a9fdb26
parent87bbc69c40d36046492d754c8d7ff02c3be6ce43
Implement ordering comparisons for type-level naturals and symbols.

This is done with two built-in type families: `CmpNat and `CmpSymbol`.
Both of these return a promoted `Ordering` type (EQ, LT, or GT).
compiler/prelude/PrelNames.lhs
compiler/prelude/TysWiredIn.lhs
compiler/typecheck/TcTypeNats.hs