std.algorithm Map using a external variable
Zardoz
luis.panadero at gmail.com
Mon Dec 10 10:21:47 PST 2012
I'm trying to use Map with a code like this :
...
immutable int m = 10;
int[] caca = [1,2,3,4];
auto caca2 = map!( (a) {return a * m;})(caca);
writeln(caca2);
...
I get a Segmentation fault some times:
The most interesting point it's that depends of the code around
of it ins the same program. for example If a use getopt at the
begin of my program, then seg fault, etc...
Looks that there some weird error in gdc 4.6.3
PD: Later I will put the whole code so any can see if I doing
some weird thing that make map crazy
More information about the Digitalmars-d-learn
mailing list