- replace uint buffer lengths with size_t
- add line-by-line opApply to Stream and InputStream (due to Regan Heath)
int opApply(int delegate(inout char[] line) dg)
int opApply(int delegate(inout ulong n, inout char[] line) dg)
int opApply(int delegate(inout wchar[] line) dg)
int opApply(int delegate(inout ulong n, inout wchar[] line) dg)- move readable/writeable/seekable tests from contracts to the body since phobos is compiled in release mode and users can easily try to write to an unwritable stream
- return "this" from writef and writefln to allow chaining (eg flush)
- fix TArrayStream read/write to check for "eof" (Derick Eddington)
- make SliceStream preserve the source buffer position if seekable and pay attention to isOpen (Derick)
- implement available() for more stream types (Derick)
- copyFrom bug fixes and position preserving if seekable (Derick)
- move the initialization of the BOMs to the initializer instead of the module constructor.
- make isopen protected (from private) so that subclasses can see it.
- more unittest (Derick and Ben)
- fix File.size() bug on Windows
- fix File.open() error message to say "Cannot open or create file"
module foo.bar;then bar is not in scope, one must use foo.bar.
IPv6 not supported but the C interface for it should all be there. Split up socket.d and put the C stuff in std.c modules. std.c.linux.linux updated because most of the socket functions are actually regular I/O functions. Added classes Protocol and Service. Added Socket.accepting() to allow derived classes to be accepted. Documentation and samples updated. Fixed major bug in the linux version.
Note: This is a library only change, the dmd executables are still at 0.111.
I've attached modified versions of std.stream and mmfile and the help section for std.mmfile and std.stream. The std.mmfile changes are:The std.stream changes are:
- change module declaration to std.mmfile
- change class declaration to not be auto
- add mMode read-only property to get the file mode of type MmFile.Mode
- added Dave Fladebo's performance improvements for buffered readLine
- fixed a bug in read/write cfloat/cdouble/creal endian support
- uncommented MmFileStream and cleaned it up to use MmFile's mode property.
template foo(T:T[])now correctly resolve T in foo(int[]) to int rather than int[].
char[][] foo; foo = new char[][45]; // new, correct way to allocate array of 45 strings //foo = new char[45][]; // old, now wrong, way
int[3][4] a; // a is 4 arrays of 3 arrays of ints int b[4][3]; // b is 4 arrays of 3 arrays of ints
byte b = 0x10; // ok ubyte c = 0x100; // error byte d = 0x80; // error ubyte e = 0x80; // ok