by mhitza · 4y ago · 0 comments
Personally I think it wouldn't hurt if more strongly/statically typed languages took a note from the GHC compiler and had an option like -fdefer-type-errors[1]. That way one can write the sloppy/clever/prototype code, then disable the flag and make the program sturdy in the presence of failure.
[1] https://downloads.haskell.org/~ghc/7.8.1/docs/html/users_gui...
Last night I was playing with an OCaml Web framework called Dream [1]. The change-recompile-reload loops were fast enough that I never had to wait. (OCaml supports separate / incremental compilation, so the benefits tend to scale on larger projects.) It's not a silver bullet, but it might slightly change your mind about why you like dynamic languages. :)
But I find those two a little on the less featurefull side. I think by the time typeclasses are in things get slow really fast. It's features like that, that just add a lot of complexity at compile time.
Just had a look at Dream. Good to see httpaf AND mirage (microkernel) targets! And it allows coding in Reason/Melange, which I find a very nice syntax especially for server-side code. Thanks for mentioning.
However I've recently switched to chicken scheme for that purpose, not because Haskell isn't good but because of type friction I encounter when trying to use new libraries.
It's not a rant at Haskell, as I assume were I to use it on a daily basis it would be a nice fit. But as I'm using it a couple of times a year, it doesn't work out.
What's your preferred gui library for Chicken for this sort of thing?