Skip to content

Commit aca1749

Browse files
committed
Don't leave lingering files in doc tests
Closes #11234
1 parent 0daaeab commit aca1749

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

src/libstd/io/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ Some examples of obvious things you might want to do
5353
# let _g = ::std::io::ignore_io_error();
5454
let mut file = File::create(&Path::new("message.txt"));
5555
file.write(bytes!("hello, file!\n"));
56+
# drop(file);
57+
# ::std::io::fs::unlink(&Path::new("message.txt"));
5658
```
5759
5860
* Iterate over the lines of a file

src/test/compile-fail/lint-missing-doc.rs

+1
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ pub trait A {
5050
/// dox
5151
fn foo_with_impl() {}
5252
}
53+
#[allow(missing_doc)]
5354
trait B {
5455
fn foo();
5556
fn foo_with_impl() {}

0 commit comments

Comments
 (0)