What if we were to build an alternative syntax for Haskell?

  • @bss03
    link
    38 months ago

    Article didn’t explain the desire to change some common operators, tho it implied it would.

    I’m uninterested in trying to graft an alternative front end on to GHC and I don’t think it would actually help the ecosystem much.

    If we still had a language standard, I think a transpiler from a new front end to standard Haskell might be interesting. I don’t think the front end is that bad tho. Yes, records are troublesome and several languages have improved on them, but they aren’t often a real pain point for me until they interact with the type system, and a new front end is unlikely to fix that. (Extensible record types ala Purescript might?)

    I think it is generally a good idea for an (infix) operator to have a equivalent (prefix) function, but I don’t think requiring at the language level buys you much. Good names is a cultural issue and doesn’t have a technological solution (as much as I want one). People that want to strongly encourage use of an operator will just pick a name that’s hard to type and pronounce and easynto confuse with other names.

    I do wish we had mixfix operators ala Agda. I also think more precedence levels might help, tho I’ve always thought having the computer build/verify a transitive closure from pairwise ordering statements would be more flexible.

    Anyway, I don’t think this is thought through enough, and I don’t think my thoughts here are complete enough either.