[Issue 24082] New: std.int128.Int128: add toString that supports std.format

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Aug 11 20:58:33 UTC 2023


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

          Issue ID: 24082
           Summary: std.int128.Int128: add toString that supports
                    std.format
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: phobos
          Assignee: nobody at puremagic.com
          Reporter: n8sh.secondary at hotmail.com

```
import std;
writeln(Int128.min);
```

Current output: "Int128(Cent(0, 9223372036854775808))"
Proposed output: "-170141183460469231731687303715884105728"

```
import std;
writefln("%x", Int128.min);
```

Currently throws std.format.FormatException "Expected '%s' format specifier for
type 'Int128'"
Proposed output: "7fffffffffffffffffffffffffffffff"

--


More information about the Digitalmars-d-bugs mailing list