Skip to content

Commit ed7c9cd

Browse files
chore(deps): update rust crate proptest to 1.4.0 (#36)
* chore(deps): update rust crate proptest to 1.4.0 * chore: work around rust-lang/rust#117796 These changes work around a recent change in rustdoc's behavior. The patch was suggested by @Nemo157. * chore: fix test compilation under non-std --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Alejandro González <[email protected]>
1 parent 2c857de commit ed7c9cd

File tree

5 files changed

+41
-5
lines changed

5 files changed

+41
-5
lines changed

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ typed-arena = { version = "2.0.2", default-features = false }
1919
log = "0.4.20"
2020

2121
[dev-dependencies]
22-
proptest = "1.3.0"
22+
proptest = "1.4.0"
2323
proptest-derive = "0.4.0"
2424
miniz_oxide = "0.7.1"
2525

src/deflate.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,18 @@ impl<W: Write> Drop for DeflateEncoder<W> {
161161
}
162162
}
163163

164+
// Boilerplate to make latest Rustdoc happy: https://github.com/rust-lang/rust/issues/117796
165+
#[cfg(all(doc, feature = "std"))]
166+
impl<W: crate::io::Write> std::io::Write for DeflateEncoder<W> {
167+
fn write(&mut self, _buf: &[u8]) -> std::io::Result<usize> {
168+
unimplemented!()
169+
}
170+
171+
fn flush(&mut self) -> std::io::Result<()> {
172+
unimplemented!()
173+
}
174+
}
175+
164176
/// Deflate a part, to allow for chunked, streaming compression with [`DeflateEncoder`].
165177
/// It is possible to call this function multiple times in a row, shifting
166178
/// instart and inend to next bytes of the data. If instart is larger than 0, then

src/gzip.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,3 +101,15 @@ impl<W: Write> Drop for GzipEncoder<W> {
101101
self._finish().ok();
102102
}
103103
}
104+
105+
// Boilerplate to make latest Rustdoc happy: https://github.com/rust-lang/rust/issues/117796
106+
#[cfg(all(doc, feature = "std"))]
107+
impl<W: crate::io::Write> std::io::Write for GzipEncoder<W> {
108+
fn write(&mut self, _buf: &[u8]) -> std::io::Result<usize> {
109+
unimplemented!()
110+
}
111+
112+
fn flush(&mut self) -> std::io::Result<()> {
113+
unimplemented!()
114+
}
115+
}

src/zlib.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,3 +94,15 @@ impl<W: Write> Drop for ZlibEncoder<W> {
9494
self._finish().ok();
9595
}
9696
}
97+
98+
// Boilerplate to make latest Rustdoc happy: https://github.com/rust-lang/rust/issues/117796
99+
#[cfg(all(doc, feature = "std"))]
100+
impl<W: crate::io::Write> std::io::Write for ZlibEncoder<W> {
101+
fn write(&mut self, _buf: &[u8]) -> std::io::Result<usize> {
102+
unimplemented!()
103+
}
104+
105+
fn flush(&mut self) -> std::io::Result<()> {
106+
unimplemented!()
107+
}
108+
}

0 commit comments

Comments
 (0)