Techern-archived / Varint-rs

Variable-length integer implementation in Rust
Apache License 2.0
7 stars 2 forks source link

Implement VarintRead and VarintWrite for all readers and writers (resp.) #5

Open nham opened 8 years ago

CruzBishop commented 8 years ago

Thank you for this :) I'm not at my usual computer at the moment but I'll review it properly and make any changes (if required) through the week

nham commented 8 years ago

Thinking about this again, is there any impediment to just doing:

impl<T> VarintRead for T where T: Read { }
impl<T> VarintWrite for T where T: Write { }

I've updated it to this in the PR, and it seems to be working fine.

CruzBishop commented 8 years ago

Sorry about this taking so long; I've just updated this in IoOperations so I'll merge this in while #4 is being worked on

koliyo commented 1 year ago

What happened to this PR?

koliyo commented 1 year ago

Use this instead: https://docs.rs/integer-encoding/latest/integer_encoding/trait.VarIntReader.html