Skip to content

Commit 220a2dd

Browse files
committed
transpile: use raw r#"" string to avoid escaping " in fn emit_rust_toolchain
1 parent bcb0a39 commit 220a2dd

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

  • c2rust-transpile/src/build_files

c2rust-transpile/src/build_files/mod.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -292,11 +292,11 @@ fn emit_rust_toolchain(tcfg: &TranspilerConfig, build_dir: &Path) {
292292
let output_path = build_dir.join("rust-toolchain.toml");
293293
let toolchain = tcfg.edition.toolchain().strip_prefix("+").unwrap();
294294
let output = format!(
295-
"
295+
r#"
296296
[toolchain]
297-
channel = \"{toolchain}\"
298-
components = [\"rustfmt\"]
299-
"
297+
channel = "{toolchain}"
298+
components = ["rustfmt"]
299+
"#
300300
);
301301
let output = output.trim_start();
302302
maybe_write_to_file(&output_path, output, tcfg.overwrite_existing);

0 commit comments

Comments
 (0)