Comment

Comment by throwaway81523

Addition: I'm doing other stuff so still haven't read much of this, but one of the first things I see is "Since the above type depends on the value of the type DatabaseContext ... this construct is, unfortunately, impossible in Haskell."

I think it could have used an explanation of what DatabaseContext is supposed to be. It looks to me like the -XDataKinds extension could handle it. There is also Dependent Haskell on its way, though I don't know the current status of it. And again, look at Ur/Web, which I think had this under control. I was expecting to see something about Pi types, like in the Power of Pi paper which describes using them for database schemas. Maybe that is further in.

https://cs.ru.nl/~wouters/Publications/ThePowerOfPi.pdf

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton