Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Haskell has support for reflection, using packages like Data.Data[1] (which is part of base). The type theory behind it is fairly advanced; I've never successfully used gfold on my own, but it's the kind of thing where one would put a library routine in that could generate a select box from a type that derives Data and Typeable.

I bring this up to suggest that this isn't necessarily a core limitation of ML languages like Elm, just a feature that Elm could borrow from Haskell in the future to address this problem without sacrificing typing.

[1]: https://hackage.haskell.org/package/base-4.9.0.0/docs/Data-D...



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: