Git Product home page Git Product logo

Comments (9)

ekmett avatar ekmett commented on August 28, 2024

We can do that with a major version bump and a clearly worded CHANGELOG entry. I don't think anybody but me has adopted IterT yet.

from free.

vlopezj avatar vlopezj commented on August 28, 2024

On the other hand, this new instances are not fully satisfactory. Ideally, if the underlying monad implements MonadPlus, the first computation which completes and does so without errors should be returned.

The instance for plain IterT Identity (which is not MonadPlus) is quite straightforward, and causes no conflicts. I'll add that one first, and then think whether it's possible to make IterT into a true MonadPlus transformer.

from free.

ekmett avatar ekmett commented on August 28, 2024

The problem with making instances for IterT Identity is that it precludes any general solution by overlap and requires a FlexibleInstance, which in my experience makes its selection brittle.

Of course we can make a separate Control.Monad.Iter that has a concrete Iter with that instance, which would let us have a nice, explainable

data Iter a = Stop a | Step (Iter a)

with obvious racing.

from free.

vlopezj avatar vlopezj commented on August 28, 2024

The behaviour described above is now in commit 7b3cbcb , on the iter-monadplus branch.

The approach is similar to the one for the ErrorT monad transformer, where the behaviour of the underlying monad is disregarded when implementing MonadPlus.

from free.

ekmett avatar ekmett commented on August 28, 2024

I'm cautiously optimistic about the new change. The main question I'd have is how to get the word out about it.

from free.

vlopezj avatar vlopezj commented on August 28, 2024

How about some explanation at the top of the Haddock page, and an usage example? Together with the major version bump, it could be enough for interested users to notice.

from free.

ekmett avatar ekmett commented on August 28, 2024

That sounds like a plan to me. Feel free to merge into master.

On Wed, Jul 9, 2014 at 11:21 AM, Víctor López Juan <[email protected]

wrote:

How about some explanation at the top of the Haddock page, and an usage
example? Together with the major version bump, it could be enough for
interested users to notice.


Reply to this email directly or view it on GitHub
#52 (comment).

from free.

vlopezj avatar vlopezj commented on August 28, 2024

from free.

ekmett avatar ekmett commented on August 28, 2024

Have I mentioned that you, sir, are awesome?

from free.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.