Skip to content

Commit 2c9184d

Browse files
committed
Touch up line lengths
1 parent 277e089 commit 2c9184d

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

src/cargo/util/toml.rs

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1383,13 +1383,19 @@ fn normalize(package_root: &Path,
13831383
ret
13841384
}
13851385

1386-
fn inferred_bin_path(bin: &TomlBinTarget, package_root: &Path, lib: bool, bin_len: usize) -> PathBuf {
1387-
// we have a lib with multiple bins, so the bins are expected to be located inside src/bin
1386+
fn inferred_bin_path(bin: &TomlBinTarget,
1387+
package_root: &Path,
1388+
lib: bool,
1389+
bin_len: usize) -> PathBuf {
1390+
// we have a lib with multiple bins, so the bins are expected to be located
1391+
// inside src/bin
13881392
if lib && bin_len > 1 {
1389-
return Path::new("src").join("bin").join(&format!("{}.rs", bin.name())).to_path_buf()
1393+
return Path::new("src").join("bin").join(&format!("{}.rs", bin.name()))
1394+
.to_path_buf()
13901395
}
13911396

1392-
// we have a lib with one bin, so it's either src/main.rs, src/bin/foo.rs or src/bin/main.rs
1397+
// we have a lib with one bin, so it's either src/main.rs, src/bin/foo.rs or
1398+
// src/bin/main.rs
13931399
if lib && bin_len == 1 {
13941400
let path = Path::new("src").join(&format!("main.rs"));
13951401
if package_root.join(&path).exists() {

0 commit comments

Comments
 (0)