>   tricky 0 = constant 0
>   tricky d = add e0 e1
>     where
>       (e0, e1) = fork (tricky (d-1))

Oops, I just realised that this isn't a very good example of
expressible sharing!  The problem is that it doesn't take any inputs,
and expressible sharing just collapses (partially evaluates) operators
when they are applied to constants.  A better example would be
something that takes an input, such as

  distrib a [] = []
  distrib a (x:xs) = (a0, x) : distrib a1 xs
    where
      (a0, a1) = fork a

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

Reply via email to