Closed natefaubion closed 7 years ago
Do you think it makes sense to have a sum for SqlTop
? I'm not sure there are many (any?) cases where either query or module are acceptable in the same place. It seems like maybe they should be separate types. Either that, or we could use a phantom type / pseudo-GADT thing, so that we don't have to pattern match SqlTop
, as we'll already know which of the two options it is from the type.
That's a good point. I'll put them in separate types.
Done.
I left the existing functions (
parse
,encodeJson
, etc) to work on justSqlF
expressions, addingparseTop
, etc for the module/query productions. I can get rid of this distinction though and require everything to build either aQuery
orModule
. Which would you prefer?