On 3/23/14, 4:28 PM, Anonymous wrote:
dchar front(char[] s) { uint c = s[0]; ubyte p = ~s[0]; if (p>>7) return c; c = c<<8 | s[1]; if (p>>5) return c; c = c<<8 | s[2]; if (p>>4) return c; return c<<8 | s[3]; }
That's smaller but doesn't seem to do the same! Andrei