java: public void freeBefore(int pos) {assert pos >= 0;assert pos <= nextPos;final int newCount = nextPos - pos;assert newCount <= count: "newCount=" + newCount + " count=" + count;assert newCount <= buffer.length: "newCount=" + newCount + " buf.length=" + buffer.length;count = newCount;}
C#: public void FreeBefore(int pos){Debug.Assert(pos >= 0);Debug.Assert(pos <= nextPos);int newCount = nextPos - pos;Debug.Assert(newCount <= count, "newCount=" + newCount + " count=" + count);Debug.Assert(newCount <= buffer.Length, "newCount=" + newCount + " buf.length=" + buffer.Length);count = newCount;}