Parallelism Map and Reduce

Zardoz luis.panadero at gmail.com
Wed Dec 12 05:47:21 PST 2012


On Tuesday, 11 December 2012 at 17:50:31 UTC, Ali Çehreli wrote:
> On 12/11/2012 08:12 AM, Zardoz wrote:
>
>
> Could you please move MapIntegrator() to module-level. Then it 
> should work.
>
> Ali

I try it and now even with normal Map function give me errors 
with dmd !

public Entity MapIntegrator ( Entity me) {
   me.Integrador3Orden ();
   return me;
}

void main() {
   Entity[] objects;
...
   objects = array( map!MapIntegrator(objects) );
...
}

With this error :
dmd -w -wi -version=SReduction simulator.d entity.d vector.d 
-ofreduceSim
simulator.d(194): Error: template 
std.algorithm.map!(MapIntegrator).map does not match any function 
template declaration
/usr/include/dmd/phobos/std/algorithm.d(369): Error: template 
std.algorithm.map!(MapIntegrator).map(Range) if 
(isInputRange!(Unqual!(Range))) cannot deduce template function 
from argument types !()(Entity[])





More information about the Digitalmars-d-learn mailing list