Parallelism Map and Reduce

Ali Çehreli acehreli at yahoo.com
Tue Dec 11 09:50:31 PST 2012


On 12/11/2012 08:12 AM, Zardoz wrote:

 > I try to use a function instead of a lambda function I'm keep getting
 > compiler errors. Code :
 > Entity MapIntegrator (ref Entity me) {
 > me.Integrador3Orden (iDeltaT);
 > return me;
 > }
 > objects = array( taskPool.map!MapIntegrator(objects) );
 >
 > With taskPool.Map I get this errors :
 > simulator.d(196): Error: template instance map!(MapIntegrator) cannot
 > use local 'MapIntegrator' as parameter to non-global template
 > map(functions...)

Could you please move MapIntegrator() to module-level. Then it should work.

Ali



More information about the Digitalmars-d-learn mailing list