On Saturday, 13 December 2014 at 10:09:27 UTC, Charles Hixson via
Digitalmars-d-learn wrote:
Is there a standard way to do this? The code below is
untested, as I haven't yet written the x7to8 routine, and came
up with a better way to do what this was to accomplish, but it
feels as if this
On Saturday, 13 December 2014 at 11:20:21 UTC, Manolo wrote:
On Saturday, 13 December 2014 at 10:09:27 UTC, Charles Hixson
via Digitalmars-d-learn wrote:
Is there a standard way to do this? The code below is
untested, as I haven't yet written the x7to8 routine, and came
up with a better way
On Saturday, 13 December 2014 at 19:52:33 UTC, Charles Hixson via
Digitalmars-d-learn wrote:
On 12/13/2014 03:20 AM, Manolo via Digitalmars-d-learn wrote:
On Saturday, 13 December 2014 at 10:09:27 UTC, Charles Hixson
via Digitalmars-d-learn wrote:
Is there a standard way to do this? The code
Charles Hixson:
byte[]x8to7 (ubyte[] bin)
Better to add some annotations, like pure, @safe, nothrow, if you
can, and to annotate the bin with an in.
intfByte, fBit;
It's probably better to define them as size_t.
switch (fBit)
I think D doesn't yet allow this
Your comments would be reasonable if this were destined for a library,
but I haven't even finished checking it (and probably won't since I've
switched to a simple zero elimination scheme). But this is a bit
specialized for a library...a library should probably deal with
arbitrary ints from 8