For example, functions like add have a Columnable constraint.
This makes sense but at the same time every single constructor of Expr has also a Columnable constraint, so even if the Columnable proof is hidden in GADT, Expr a implies Columnable a.
In a ideal world we don't need Columnable a => Expr a unless we remove it from the Expr constructors altogether. That way Expr could live outside of a DataFrame and possibly have a Functor and Applicative instance.
And when Columnable is required it can be added a constraint as it is already the case.
Just a thought.
For example, functions like
addhave aColumnableconstraint.This makes sense but at the same time every single constructor of
Exprhas also aColumnableconstraint, so even if theColumnableproof is hidden in GADT,Expr aimpliesColumnable a.In a ideal world we don't need
Columnable a => Expr aunless we remove it from theExprconstructors altogether. That wayExprcould live outside of a DataFrame and possibly have a Functor and Applicative instance.And when
Columnableis required it can be added a constraint as it is already the case.Just a thought.