Commit Graph
15 Commits
Author SHA1 Message Date
Jamie Turner 7b63fa034f Add resume() method to ByteBuf that restores prior write position. 2015-07-02 17:19:43 -07:00
James Bielman d2b4cc3870 RingBuf: Fix edge cases with mark/reset.
- This fixes #25 and fixes #26.

- Move the mark state into a 'Mark' enum.

- Store both 'pos' and 'len' inside the mark because both
  are needed to distinguish between full/empty states. This
  fixes 'reset' setting 'len' to zero when the buffer was
  full when marked.

- Clear the mark when the length of the marked input range
  exceeds the capacity. Fixes bugs with the mark not being
  cleared correctly on writes.

- Add test cases.
2015-06-02 23:51:57 -07:00
Florian Hartwig d25958970e + isn't implemented on Vec any more 2015-05-09 17:58:23 +02:00
Dan Burkert 4d645c7f53 add mark/reset feature to ByteBuf and RingBuf 2015-04-11 15:18:32 -07:00
Florian Hartwig 40f1d1aa77 Add some basic tests for RingBuf 2015-04-09 23:18:16 +02:00
Carl Lerche 29e5dc72bb Get compiling on Rust 1.0 beta 2015-04-03 23:45:34 -07:00
Victor Berger 635274752b Update for new blanket impl rules. 2015-04-03 22:46:10 +02:00
Carl Lerche f0ce42d9c3 Track Rust nightlies 2015-04-01 20:09:20 -07:00
Carl Lerche 8f526231d8 Track Rust nightlies 2015-03-25 12:44:38 -07:00
Carl Lerche 83680dda27 Implement Source for std::io::Read 2015-03-24 22:10:29 -07:00
Carl Lerche bd2c643e17 Flesh out ToBytes, ByteStr::concat, and ByteStr eq 2015-03-23 23:22:21 -07:00
Carl Lerche a87dea0bd4 Track Rust master 2015-03-23 17:12:39 -07:00
Florian Hartwig 3f9b7f6d46 Fix errors and warnings with current rust nightly 2015-03-19 16:23:29 +01:00
Carl Lerche 7444721d98 Implement Debug for Bytes 2015-02-17 12:40:15 -08:00
Carl Lerche 3c4ebb85f0 WIP - Implement abstractions for working with bytes 2015-02-09 21:24:53 -08:00