Auto merge of #40451 - ollie27:rustdoc_impls_js_escape, r=GuillaumeGomez
rustdoc: Fix string escaping in implementors js files The generated HTML can contain quotes so we need to make sure they are escaped before inserting into the js files.
This commit is contained in:
commit
a5483a7f36
@ -763,7 +763,7 @@ fn write_shared(cx: &Context,
|
|||||||
// going on). If they're in different crates then the crate defining
|
// going on). If they're in different crates then the crate defining
|
||||||
// the trait will be interested in our implementation.
|
// the trait will be interested in our implementation.
|
||||||
if imp.def_id.krate == did.krate { continue }
|
if imp.def_id.krate == did.krate { continue }
|
||||||
write!(implementors, r#""{}","#, imp.impl_).unwrap();
|
write!(implementors, "{},", as_json(&imp.impl_.to_string())).unwrap();
|
||||||
}
|
}
|
||||||
implementors.push_str("];");
|
implementors.push_str("];");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user