4 ms·
Racket has delimited continuations (from which you can build effects w/o the types) and Datalog as a #lang. Sure, not a lot of types unless you use Typed Racket
by the-smug-one 6y ago
Racket has delimited continuations (from which you can build effects w/o the types) and Datalog as a #lang. Sure, not a lot of types unless you use Typed Racket, that's true. I also don't see why you couldn't swap out Datalog with another constraint system, like that described in Monadic Constraints (Wadler, Stuckey, Sch-something).
I think the effect system is cool. How does Flix differ from Eff or Unison in this matter?
- jorkadeen 6y agoThe Datalog implementation in Racket is neat, but does not support stratified negation nor are the Datalog constraint first-class. Both features make it significantly more practical to work with Datalog. Also, the Flix type system ensures - at compile-time - that all first-class Datalog values constructed at run-time are stratified. The effect system in Flix is focused on a single effect: purity. It is very fine-grained (compared to e.g. systems based on rows) and it supports effect inference and effect polymorphism. Eff and Unison have richer effect systems - based on algebraic effects - which allow re-interpretation of effects. However these effects system struggle more with effect inference. For example, I believe that in Eff you only have a restricted form of effect polymorphism / the use of higher-order functions is more limited. (I am one of the authors of Flix)
- the-smug-one 6y ago> Also, the Flix type system ensures - at compile-time - that all first-class Datalog values constructed at run-time are stratified. That does sound powerful! To be honest I have no idea what the implications of that are - but I guess that's why it's research! Re: effect system. The reason that I think algebraic effects are so cool is that they allow for trackable, side-effectful, and powerful abstractions. To me it sounds like Flix's Pure/Impure effects offer a fine-grained form of taint tracking. Why do you think I should be excited about this? For example, why not Haskell's monad solution? I hope I don't come off as confrontational, I'm genuinely interested :-).
- jorkadeen 6y agoI think you would want both: algebraic effects and very fine-grained effect reasoning. For example, in all most all languages it is vital that functions such as "equal" and "hash" are pure. It is an open problem how to combine our fine-grained Boolean unification-based effect system with other algebraic effect systems (e.g. row polymorphic ones). I hope the future will tell :)