From 4f9c30fb676482a5148f28c0728b5280246a9886 Mon Sep 17 00:00:00 2001 From: Jannis Christopher Köhl Date: Thu, 25 Aug 2022 16:43:46 +0000 Subject: Add initial version of value analysis and dataflow constant propagation --- compiler/rustc_graphviz/src/lib.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'compiler/rustc_graphviz/src') diff --git a/compiler/rustc_graphviz/src/lib.rs b/compiler/rustc_graphviz/src/lib.rs index 3c1bb553266..401d3f6689c 100644 --- a/compiler/rustc_graphviz/src/lib.rs +++ b/compiler/rustc_graphviz/src/lib.rs @@ -471,7 +471,11 @@ pub trait Labeller<'a> { /// Escape tags in such a way that it is suitable for inclusion in a /// Graphviz HTML label. pub fn escape_html(s: &str) -> String { - s.replace('&', "&").replace('\"', """).replace('<', "<").replace('>', ">") + s.replace('&', "&") + .replace('\"', """) + .replace('<', "<") + .replace('>', ">") + .replace('\n', "
") } impl<'a> LabelText<'a> { -- cgit 1.4.1-3-g733a5