www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 13755] New: std.file: fopencookie, fmemopen missing

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

          Issue ID: 13755
           Summary: std.file: fopencookie, fmemopen missing
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: Phobos
          Assignee: nobody puremagic.com
          Reporter: danny.milo gmail.com

fopencookie, fmemopen, open_memstream, open_wmemstream are missing in std.file
.

If std.file.File is actually supposed to be a wrapper for FILE* (is it?), it
would be nice to have these available.

fmemopen, open_memstream and open_wmemstream are Posix standard functions.

These deal with reading/writing from an array using File I/O (i.e. like C++
sstream, Python StringIO).

--

fopencookie is a GNU extension.

This would allow to register your own reading/writing implementation per
instance.

It would also be useful for interoperability with C libraries using FILE* in
this manner in their interface.

--
Nov 19 2014