OK, this one surprised me, all that remains is for me to find out why it shouldn't have done:
reduce ! ( ( a , b ) { return a + b ; } ) ( 0.0 , outputData )
works just fine, but:
reduce ! ( function double ( double a , double b ) { return a + b ; } )
( 0.0 , outputData )
results in:
pi_d2_sequentialMap.d(45): Error: function
std.algorithm.reduce!(function double(double a, double b)
{
return a + b;
}
).reduce!(double,Map!(partialSum,Tuple!(int,int,double)[])).reduce.__funcliteral1
cannot access frame of function pi_d2_sequentialMap.execute.__funcliteral1
pi_d2_sequentialMap.d(45): Error: function
std.algorithm.reduce!(function double(double a, double b)
{
return a + b;
}
).reduce!(double,Map!(partialSum,Tuple!(int,int,double)[])).reduce.__funcliteral1
cannot access frame of function pi_d2_sequentialMap.execute.__funcliteral1
which I think qualifies for the label "incomprehensible". Not to
mention repetitious.
PS If you ask why not:
reduce ! ( "a+b" ) ( 0.0 , outputData )
I find this somehow unacceptable. It's the string, its not a function.
Fine, my problem, but that still leaves the above.
--
Russel.
=============================================================================
Dr Russel Winder t: +44 20 7585 2200 voip: sip:[email protected]
41 Buckmaster Road m: +44 7770 465 077 xmpp: [email protected]
London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
signature.asc
Description: This is a digitally signed message part
