David Menendez wrote:
Heinrich Apfelmus wrote:
David Menendez wrote:
Heinrich Apfelmus wrote:
Even then, the results are mixed. The Church-encoding shines in GHCi as
it should, but loses its advantage when the code is being compiled. I
guess we have to look at the core if we want to know
Eugene Kirpichov wrote:
I took a toy problem - find the first node satisfying a predicate in a
binary tree, started with a naive Maybe-based implementation - and
experimented with 3 ways of changing the program:
- Church-encode the Maybe
- Convert the program into CPS
- Defunctionalize
On Sun, Nov 1, 2009 at 7:12 AM, Heinrich Apfelmus
apfel...@quantentunnel.de wrote:
Even then, the results are mixed. The Church-encoding shines in GHCi as
it should, but loses its advantage when the code is being compiled. I
guess we have to look at the core if we want to know what exactly is
David Menendez wrote:
On Sun, Nov 1, 2009 at 7:12 AM, Heinrich Apfelmus
apfel...@quantentunnel.de wrote:
Even then, the results are mixed. The Church-encoding shines in GHCi as
it should, but loses its advantage when the code is being compiled. I
guess we have to look at the core if we want
On Sun, Nov 1, 2009 at 12:31 PM, Heinrich Apfelmus
apfel...@quantentunnel.de wrote:
David Menendez wrote:
On Sun, Nov 1, 2009 at 7:12 AM, Heinrich Apfelmus
apfel...@quantentunnel.de wrote:
Even then, the results are mixed. The Church-encoding shines in GHCi as
it should, but loses its