Boost logo

Boost :

Subject: Re: [boost] Interest in a list comprehension library?
From: Larry Evans (cppljevans_at_[hidden])
Date: 2010-12-20 05:37:15


On 12/19/10 22:33, Larry Evans wrote:
> On 12/19/10 19:54, Larry Evans wrote:
> [snip]
>> Actually, fcpp already has it in monad.h. Fcpp is available at sourceforge:
>>
>> http://sourceforge.net/projects/fcpp/
>>
> [snip]
> OOPS, That doesn't look like it's maintained and doesn't have any test
> drivers or examples. This location might be more complete:
>
> http://www.cc.gatech.edu/~yannis/fc++/download.html
>
[snip]

Brent,

Using the fc++ library, the attached c++ program produces output:

--{-- output ---
make -k run
/home/evansl/prog_dev/boost-svn/ro/trunk/sandbox-local/build/gcc4_4n/boost-svn/ro/trunk/sandbox-local/fc++/sourceforge/sandbox/monad_list_comprehension.exe

---------:41
1,3
1,4
2,3
2,4
---------

Compilation finished at Mon Dec 20 04:28:48

--}-- output ---

Actually, the following line(around line 587):
             typedef typename OrigET::template Go<Dummy>::BE BE1;
had to be removed from the fc++ lambda.h file to enable
compilation of the attached.

Maybe you could merge the best ideas from both your and fc++'s
version of list comprehension. Anyway, I thought it might
be useful to see how another list comprehension was implemented.

  -regards,
  Larry




Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk