freek icon indicating copy to clipboard operation
freek copied to clipboard

Confusion between DSL/Effects

Open aloiscochard opened this issue 9 years ago • 4 comments
trafficstars

HI @mandubian,

I'm slightly concern about what I see to be a little abuse of terminology which might push newcomers in a wrong way of thinking.

Correct me if I'm wrong, but what you are really doing here is combining algebras, that's it. The fact that Free can be used to build a pseudo-effect system is an incident, and nothing to do with this library, so I think you should really avoid mentioning "effect" when it is not the subject.

I friendly encourage you to rename FXNil and rephrase relevant sentences in the README.

Hope that makes sens to you as well?

Thanks for the lib :-)

aloiscochard avatar Aug 02 '16 18:08 aloiscochard

That's not false even if the vast majority of DSL we tend to use are compiled into effectful computations actually... That's why I speak about effects but as you say, effects aren't the primary target. I called FX but that wasn't certainly a so nice idea...

Anyway, compared to Emm, it makes things less risky between combining DSL with Coproduct & monadic return types stack with Onion...

mandubian avatar Aug 02 '16 22:08 mandubian

I'll change a few sentences to remove this fake effect-oriented impression... I think there is still something better to do with effects... Eff & others are yet a bit too hairy IMHO...

mandubian avatar Aug 02 '16 23:08 mandubian

Yep for sure it's not false, but it's just one of many use case that your library can support.

It is more general than Emm or equivalent, and it would be a shame to give a fake impression that it is dedicated to effect handling.

Thanks a lot for taking my remark into consideration :-) I can't wait to dive more into it when getting to impl. next-gen Free in scalaz8!

On effect per se, I'm personally fine with transformers. Scala have a poor inference that make them not so handy, but in general I find them quite elegant to use... but we digress my friend ;)

aloiscochard avatar Aug 03 '16 08:08 aloiscochard

I'm eager to see your new Free representation actually! I've tried pushing optimized CoproductK structure for compiling recently in Freek... There are things to do around these ideas of optimized structures for compile-time & runtime ;)

And no it's no digression at all :D In Scala, transformers have poor inference as you say (even if SI2712 patch improves a lot the way we can infer HK thingies). But the main issue I see is that they have reached this state in which they have a very bad reputation and lots of devs are very reluctant to use them... it's stupid but it's a fact... What's really funny with Free is that I discovered it was very easy to catch for people discovering them and they have the advantage of being new & not yet considered harmful :)... Onion too even if it's quite restricted compare to transformers but corresponds to most of practical cases...

Anyway, I try to do all of that to open minds about those concepts and if it happens to be useful, it's even better... my little stone in the big building ;)

mandubian avatar Aug 03 '16 09:08 mandubian