Skip to content

Commit fcbd0d8

Browse files
committed
fixes
1 parent a57a525 commit fcbd0d8

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

scopegraphs-lib/src/render.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,6 @@ impl<'a, LABEL: Clone + Debug, DATA: Clone + RenderScopeData, CMPL: Completeness
5252
Id::new(format!("s{}", n.0)).unwrap()
5353
}
5454

55-
fn node_label(&self, n: &Scope) -> LabelText {
56-
let data = self.0.get_data(*n);
57-
LabelText::label(data.render().unwrap_or_else(|| format!("scope {}", n.0)))
58-
}
59-
fn edge_label(&self, edge: &(Scope, LABEL, Scope)) -> LabelText {
60-
LabelText::label(format!("{:?}", edge.1))
61-
}
62-
6355
fn node_shape(&'a self, node: &Scope) -> Option<LabelText<'a>> {
6456
let data = self.0.get_data(*node);
6557
if data.definition() {
@@ -68,6 +60,14 @@ impl<'a, LABEL: Clone + Debug, DATA: Clone + RenderScopeData, CMPL: Completeness
6860
Some(LabelStr(Cow::Borrowed("circle")))
6961
}
7062
}
63+
fn node_label(&self, n: &Scope) -> LabelText {
64+
let data = self.0.get_data(*n);
65+
LabelText::label(data.render().unwrap_or_else(|| format!("scope {}", n.0)))
66+
}
67+
68+
fn edge_label(&self, edge: &(Scope, LABEL, Scope)) -> LabelText {
69+
LabelText::label(format!("{:?}", edge.1))
70+
}
7171
}
7272

7373
impl<'a, LABEL: Clone, DATA: Clone, CMPL> dot::GraphWalk<'a, Scope, (Scope, LABEL, Scope)>

0 commit comments

Comments
 (0)