pub struct UPGraph {
structs: HashMap<String, HashSet<FnInfo>>,
edges: HashSet<(DefId, DefId, UPGEdge)>,
nodes: HashMap<DefId, String>,
}Expand description
Holds graph data for a single module before DOT generation.
Fields§
§structs: HashMap<String, HashSet<FnInfo>>§edges: HashSet<(DefId, DefId, UPGEdge)>§nodes: HashMap<DefId, String>Implementations§
Source§impl UPGraph
impl UPGraph
pub fn new() -> Self
pub fn add_node( &mut self, tcx: TyCtxt<'_>, node: FnInfo, custom_label: Option<String>, )
pub fn add_edge(&mut self, from: DefId, to: DefId, edge_type: UPGEdge)
pub fn upg_unit_string(&self, module_name: &str) -> String
fn node_to_dot_attr(node: &UPGNode) -> String
pub fn generate_dot_from_upg_unit(upg: &UPGUnit) -> String
Auto Trait Implementations§
impl Freeze for UPGraph
impl RefUnwindSafe for UPGraph
impl Send for UPGraph
impl Sync for UPGraph
impl Unpin for UPGraph
impl UnwindSafe for UPGraph
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more