Fractional/negative fixity?
Ben Rudiak-Gould
Benjamin.Rudiak-Gould at cl.cam.ac.uk
Fri Nov 10 12:11:58 EST 2006
apfelmus at quantentunnel.de wrote:
>I think that computable real fixity levels are useful, too.
Only finitely many operators can be declared in a given Haskell program.
Thus the strongest property you need in your set of precedence levels is
that given arbitrary finite sets of precedences A and B, with no precedence
in A being higher than any precedence in B, there should exist a precedence
higher than any in A and lower than any in B. The rationals already satisfy
this property, so there's no need for anything bigger (in the sense of being
a superset). The rationals/reals with terminating decimal expansions also
satisfy this property. The integers don't, of course. Thus there's a benefit
to extending Haskell with fractional fixities, but no additional benefit to
using any larger totally ordered set.
-- Ben
More information about the Haskell-prime
mailing list