Hi

> I'm guessing there's going to be fairly minimal performance difference.
> (Or maybe there is. My way uses a few additional pointers. But it also
> allows me to elegantly recycle existing Prelude list functions, so...)

I think we can safely assume that people using peano numbers aren't
actually overly interested in performance...

> *ALL* the instances? No.
>
> A small handful of them? Sure. How about this...

How about creating a darcs repo, a cabal package and uploading it to hackage?

Two design decisions you made could have been done differently (not
sure which is best)

If you read the lazy naturals paper it says that 4 - 8 should be 0.
This follows the whole drop 8 [] = [], not _|_

Your show function is strict. Not sure whether this is a good idea or not.

You could also include the constant infinity in your library:

infinity = LN (repeat ())

Thanks

Neil
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to