Skip to content

Commit

Permalink
Refer new Seek::stream_position() in the comment
Browse files Browse the repository at this point in the history
`reader.stream_position()` is equivalent to
`reader.seek(SeekFrom::Current(0))`.

See <rust-lang/rust#59359>.
  • Loading branch information
lo48576 committed Apr 21, 2019
1 parent e83f2e8 commit 9efae56
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pull_parser/reader.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ pub trait ParserSource: Sized + io::Read {
/// as possible.
///
/// Reader types with [`std::io::Seek`] can implement this as
/// `self.seek(SeekFrom::Current(0)).unwrap()`, but this is fallible and
/// `self.stream_position().unwrap()`, but this is fallible and
/// can be inefficient.
/// Use of [`PositionCacheReader`] is reccomended.
///
Expand Down

0 comments on commit 9efae56

Please sign in to comment.