Skip to content

Commit

Permalink
Minor changes to wording and formatting.
Browse files Browse the repository at this point in the history
  • Loading branch information
repnop committed Jan 17, 2019
1 parent 22e97da commit 80ee94c
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 6 deletions.
1 change: 1 addition & 0 deletions src/dlmalloc
Submodule dlmalloc added at c99638
1 change: 1 addition & 0 deletions src/libcompiler_builtins
Submodule libcompiler_builtins added at fe7467
1 change: 1 addition & 0 deletions src/liblibc
Submodule liblibc added at c75ca6
3 changes: 2 additions & 1 deletion src/librustdoc/config.rs
Expand Up @@ -68,7 +68,7 @@ pub struct Options {
pub should_test: bool,
/// List of arguments to pass to the test harness, if running tests.
pub test_args: Vec<String>,
/// Whether to persist the doctest executables.
/// Otional path to persist the doctest executables to.
pub persist_doctests: Option<PathBuf>,

// Options that affect the documentation process
Expand Down Expand Up @@ -123,6 +123,7 @@ impl fmt::Debug for Options {
.field("lint_cap", &self.lint_cap)
.field("should_test", &self.should_test)
.field("test_args", &self.test_args)
.field("persist_doctests", &self.persist_doctests)
.field("default_passes", &self.default_passes)
.field("manual_passes", &self.manual_passes)
.field("display_warnings", &self.display_warnings)
Expand Down
2 changes: 1 addition & 1 deletion src/librustdoc/lib.rs
Expand Up @@ -343,7 +343,7 @@ fn opts() -> Vec<RustcOptGroup> {
unstable("persist-doctests", |o| {
o.optopt("",
"persist-doctests",
"Persists the rustdoc test executables",
"Directory to persist doctest executables into",
"PATH")
}),
]
Expand Down
3 changes: 2 additions & 1 deletion src/librustdoc/test.rs
Expand Up @@ -290,7 +290,8 @@ fn run_test(test: &str, cratename: &str, filename: &FileName, line: usize,
.rsplit('/')
.next()
.unwrap()
.replace(".", "_"), line)
.replace(".", "_"),
line)
);
std::fs::create_dir_all(&path)
.expect("Couldn't create directory for doctest executables");
Expand Down
5 changes: 2 additions & 3 deletions src/test/rustdoc-ui/failed-doctest-output.stdout
Expand Up @@ -12,8 +12,7 @@ error[E0425]: cannot find value `no` in this scope
3 | no
| ^^ not found in this scope


thread '$DIR/failed-doctest-output.rs - OtherStruct (line 27)' panicked at 'couldn't compile the test', src/librustdoc/test.rs:326:13
thread '$DIR/failed-doctest-output.rs - OtherStruct (line 27)' panicked at 'couldn't compile the test', src/librustdoc/test.rs:361:13
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

---- $DIR/failed-doctest-output.rs - SomeStruct (line 11) stdout ----
Expand All @@ -22,7 +21,7 @@ thread '$DIR/failed-doctest-output.rs - SomeStruct (line 11)' panicked at 'test
thread 'main' panicked at 'oh no', $DIR/failed-doctest-output.rs:3:1
note: Run with `RUST_BACKTRACE=1` environment variable to display a backtrace.

', src/librustdoc/test.rs:395:17
', src/librustdoc/test.rs:396:17


failures:
Expand Down

0 comments on commit 80ee94c

Please sign in to comment.