You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mu is defined as extending Algebra[F, ?] ~> Id. In addition to inheriting the apply method from ~>, this also means that it inherits some methods like andThen, compose, and, and or.
In a project of mine I was using Mu to represent regular expressions, and this caught me by surprise, because I tried to add andThen and or syntax to combine two regular expressions and ran into a name collision with the methods from ~>.
I'm definitely not saying that this needs to be changed. I'm not even using Mu to represent regular expressions anymore, and nobody is using that library anyway. But I just thought that I would bring it up so to ensure that it's a conscious decision to inherit these other methods. Feel free to close this out without changes.
The text was updated successfully, but these errors were encountered:
Changing Mu so that it doesn't extend FunctionK seems pretty reasonable to me. I'll leave this open until I (or anyone else) gets a chance to make the change. Thanks for the report!
ceedubs
added a commit
to ceedubs/droste
that referenced
this issue
Oct 10, 2018
Mu
is defined as extendingAlgebra[F, ?] ~> Id
. In addition to inheriting theapply
method from~>
, this also means that it inherits some methods likeandThen
,compose
,and
, andor
.In a project of mine I was using
Mu
to represent regular expressions, and this caught me by surprise, because I tried to addandThen
andor
syntax to combine two regular expressions and ran into a name collision with the methods from~>
.I'm definitely not saying that this needs to be changed. I'm not even using
Mu
to represent regular expressions anymore, and nobody is using that library anyway. But I just thought that I would bring it up so to ensure that it's a conscious decision to inherit these other methods. Feel free to close this out without changes.The text was updated successfully, but these errors were encountered: