On 6/12/14, 3:20 PM, captaindet wrote:
import std.stdio;
import std.algorithm;
import std.file;    // not needed, but if imported, causing trouble, see
below

void main()
{
     auto names = ["one","FOO","two","three"];

// wrong code gen(*) with -release -O -inline -noboundscheck or
// with -release -inline -noboundscheck but only if std.file is imported:

     auto x = countUntil( names, "FOO" );
     write(x);
     if( 0 <= x ) writeln(" found a FOO");     // (*) not found!
}

I'm running OSX Mavericks with DMD v2.065.0. This behavior cannot be reproduced.

Reply via email to