Fix typos

This commit is contained in:
Riccardo Casatta 2022-01-05 09:39:57 +01:00
parent 9189539715
commit e860333bf3
No known key found for this signature in database
GPG Key ID: FD986A969E450397
1 changed files with 2 additions and 2 deletions

View File

@ -41,7 +41,7 @@ impl<R: Read> fmt::Debug for StreamReader<R> {
impl<R: Read> StreamReader<R> {
/// Constructs new stream reader for a given input stream `stream`
#[deprecated(since="0.28.0", note="wrap you stream into a buffered reader if necessary and use consensus_encode directly")]
#[deprecated(since="0.28.0", note="wrap your stream into a buffered reader if necessary and use consensus_encode directly")]
pub fn new(stream: R, _buffer_size: Option<usize>) -> StreamReader<R> {
StreamReader {
stream: BufReader::new(stream),
@ -49,7 +49,7 @@ impl<R: Read> StreamReader<R> {
}
/// Reads stream and parses next message from its current input
#[deprecated(since="0.28.0", note="wrap you stream into a buffered reader if necessary and use consensus_encode directly")]
#[deprecated(since="0.28.0", note="wrap your stream into a buffered reader if necessary and use consensus_encode directly")]
pub fn read_next<D: Decodable>(&mut self) -> Result<D, encode::Error> {
Decodable::consensus_decode(&mut self.stream)
}