[Issue 11816] std.stdio.slurp uninformative error message

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Feb 13 01:43:40 UTC 2019


https://issues.dlang.org/show_bug.cgi?id=11816

Basile-z <b2.temp at gmx.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |b2.temp at gmx.com
          Component|dmd                         |phobos
           Severity|normal                      |enhancement

--- Comment #2 from Basile-z <b2.temp at gmx.com> ---
For the record the idea was to catch std.conv.parse error in order to throw
something more specifc to slurp:

> Ine reason is that I want to provide helpful and verbose error messages for invalid input (e.g. "Invalid numeric value found in field 3 line 1000") - and with the "slurp" method, any input error will result in a not-so-helpful exception (e.g. "std.conv.ConvException@/usr/include/dmd/phobos/std/conv.d(2009): Unexpected 'H' when converting from type char[] to type ulong).

--


More information about the Digitalmars-d-bugs mailing list