http://d.puremagic.com/issues/show_bug.cgi?id=5163
Lars T. Kyllingstad <bugzi...@kyllingen.net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |bugzi...@kyllingen.net Component|DMD |Phobos --- Comment #1 from Lars T. Kyllingstad <bugzi...@kyllingen.net> 2010-11-05 04:38:32 PDT --- This is actually two separate issues. The first is a Phobos issue, namely that there should be a template constraint on std.array.front() that prevents it from being instantiated on void[] arrays. front() is defined as something like T front(T)(T[] array) { return array[0]; } You cannot index into a void[] array, hence the first error message. This also means that void[] cannot be a range. The second is the issue of the wrong line number, which is a bug in DMD. I'm guessing it's just bug 1913 again, so I'm marking this one as a Phobos issue. In the case of a void[] returned from std.file.read(), you need to cast it to ubyte[] before using it as a range. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------