Type-level sized Word literals???

Richard Eisenberg lists at richarde.dev
Mon Oct 30 11:15:27 UTC 2023


Modulo the backward-compatibility piece around today's type-level numbers, I'm in support of this direction. No new type machinery is needed, other than a new interpretation for literals, because type families can already infer a kind argument from the return kind. This is almost entirely a change to libraries, not to GHC itself.

Richard

> On Oct 30, 2023, at 5:32 AM, Vladislav Zavialov via ghc-devs <ghc-devs at haskell.org> wrote:
> 
> I agree caution is warranted, but I still want the type level to behave as closely as possible to the term level, where literals are currently overloaded.
> 
> I don't care if it's monomorphic literals everywhere or overloaded literals everywhere, but I oppose a discrepancy.
> 
> Vlad
> 
> On Mon, Oct 30, 2023, 10:05 Simon Peyton Jones <simon.peytonjones at gmail.com <mailto:simon.peytonjones at gmail.com>> wrote:
> I'm pretty cautious about attempting to replicate type classes (or a weaker version thereof) at the kind level.  An alternative would be to us *non-overloaded* literals.
> 
> Simon
> _______________________________________________
> ghc-devs mailing list
> ghc-devs at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-devs/attachments/20231030/c7172806/attachment.html>


More information about the ghc-devs mailing list