[Issue 22800] New: DDOC throw section for writeln is incomplete

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Feb 21 11:03:34 UTC 2022


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

          Issue ID: 22800
           Summary: DDOC throw section for writeln is incomplete
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: phobos
          Assignee: nobody at puremagic.com
          Reporter: b2.temp at gmx.com

https://dlang.org/phobos/std_stdio.html#.writeln

It states that only `StdioException` can be thrown, which is actually not true,
as shown by this

```d
import std.stdio;

nothrow void hello()
{
  try {
    writeln("Hello, World!");
  } catch (StdioException) {}
}

```

or

```d
import std.stdio;

nothrow void hello()
{
  try {
    writeln(0);
  } catch (StdioException) {}
}

```

--


More information about the Digitalmars-d-bugs mailing list