Instead it should throw ConvException. Some code and versions: import std.conv; void main() { to!real("-"); //GDC hg, using dmd 2.052 core.exception.AssertError@/.../std/array.d(373): Attempting to fetch the front of an empty array //DMD32 D Compiler v2.053 core.exception.AssertError@/.../std/array.d(372): Attempting to fetch the front of an empty array //GNU/Linux i686 }
Happens aswell when parsing "in". to!real("in");
https://github.com/D-Programming-Language/phobos/pull/270
https://github.com/D-Programming-Language/phobos/commit/e51fb3e6da41f7bbfe9005726bb9292f6afb3335