Skip to content

Commit

Permalink
Give a better error message when using CI toolchain
Browse files Browse the repository at this point in the history
This *should* be statically impossible, but the Rustwide API doesn't allow making that part of the type system.

Co-authored-by: Nemo157 <github@nemo157.com>
  • Loading branch information
jyn514 and Nemo157 committed Mar 13, 2021
1 parent 836d18b commit 07396f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/docbuilder/rustwide_builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ impl RustwideBuilder {
.prefix("essential-files")
.tempdir()?;

let toolchain_version = self.toolchain.as_dist().unwrap().name();
let toolchain_version = self.toolchain.as_dist().expect("we only use the Toolchain::dist constructor").name();
let output = build.cmd(Rustdoc { toolchain_version })
.args(&["-Zunstable-options", "--print=unversioned-files"])
.run_capture()
Expand Down

0 comments on commit 07396f1

Please sign in to comment.