Re: [IO] CharSequenceInputStream - strange code

2013-04-23 Thread sebb
On 22 April 2013 18:10, Gary Gregory wrote: > I looked at this a couple of month ago and found it equally confusing. > > I think I've finally sorted out the issues... skip() now skips the byte buffer (i.e. the same buffer as read) and AFAICT mark/reset is working OK. Also available() does now in

Re: [IO] CharSequenceInputStream - strange code

2013-04-22 Thread Gary Gregory
I looked at this a couple of month ago and found it equally confusing. Gary On Mon, Apr 22, 2013 at 12:14 PM, sebb wrote: > I'm trying to fix IO-356, and having problems. > > I think this is because the code is a bit confused. > > The read() method reads bytes from the encoded byte buffer. > >

[IO] CharSequenceInputStream - strange code

2013-04-22 Thread sebb
I'm trying to fix IO-356, and having problems. I think this is because the code is a bit confused. The read() method reads bytes from the encoded byte buffer. However skip(int) skips the underlying CharBuf, and available() checks the CharBuf I would expect read() and skip(1) to have the same ef