pub struct UnsafetyIsolationCheck<'tcx> {
pub tcx: TyCtxt<'tcx>,
pub nodes: Vec<IsolationGraphNode>,
pub related_func_def_id: Vec<DefId>,
pub uigs: Vec<UigUnit>,
pub single: Vec<UigUnit>,
}
Fields§
§tcx: TyCtxt<'tcx>
§nodes: Vec<IsolationGraphNode>
§uigs: Vec<UigUnit>
§single: Vec<UigUnit>
Implementations§
source§impl<'tcx> UnsafetyIsolationCheck<'tcx>
impl<'tcx> UnsafetyIsolationCheck<'tcx>
pub fn get_node_name_by_def_id(&self, def_id: DefId) -> String
pub fn get_node_type_by_def_id(&self, def_id: DefId) -> usize
pub fn get_node_unsafety_by_def_id(&self, def_id: DefId) -> bool
pub fn get_adjacent_nodes_by_def_id(&self, def_id: DefId) -> Vec<DefId>
pub fn get_constructor_nodes_by_def_id(&self, def_id: DefId) -> Vec<DefId>
source§impl<'tcx> UnsafetyIsolationCheck<'tcx>
impl<'tcx> UnsafetyIsolationCheck<'tcx>
pub fn handle_std_unsafe(&mut self)
pub fn get_all_std_unsafe_def_id_by_rustc_extern_crates( &mut self, tcx: TyCtxt<'tcx>, ) -> HashSet<DefId>
pub fn get_all_std_unsafe_def_id_by_treat_std_as_local_crate( &mut self, tcx: TyCtxt<'tcx>, ) -> HashSet<DefId>
pub fn analyze_uig(&self)
pub fn analyze_struct(&self)
pub fn get_struct(&self, def_id: DefId, cache: &mut HashSet<DefId>)
pub fn get_units_data(&mut self, tcx: TyCtxt<'tcx>)
pub fn process_def_id( &mut self, tcx: TyCtxt<'tcx>, def_id: DefId, visited: &mut HashSet<DefId>, unsafe_fn: &mut HashSet<DefId>, )
pub fn filter_mir(def_id: DefId) -> bool
pub fn insert_uig( &mut self, caller: DefId, callee_set: HashSet<DefId>, caller_cons: Vec<NodeType>, )
source§impl<'tcx> UnsafetyIsolationCheck<'tcx>
impl<'tcx> UnsafetyIsolationCheck<'tcx>
pub fn new(tcx: TyCtxt<'tcx>) -> Self
pub fn start(&mut self, ins: UigInstruction)
pub fn check_doc(&self, def_id: DefId)
pub fn filter_and_extend_unsafe(&mut self)
fn check_if_unsafety_doc_exists(&self, def_id: DefId) -> bool
pub fn check_if_node_exists(&self, body_did: DefId) -> bool
pub fn get_name(&self, body_did: DefId) -> String
pub fn search_constructor(&mut self, def_id: DefId) -> Vec<DefId>
pub fn get_cons_counts(&self, def_id: DefId) -> Vec<DefId>
pub fn visit_node_callees(&mut self, def_id: DefId) -> Vec<DefId>
pub fn is_crate_api_node(&self, body_did: DefId) -> bool
pub fn check_and_insert_node(&mut self, body_did: DefId)
pub fn set_method_for_constructor( &mut self, constructor_did: DefId, method_did: DefId, )
pub fn set_caller_for_callee(&mut self, caller_did: DefId, callee_did: DefId)
pub fn show_nodes(&self)
Auto Trait Implementations§
impl<'tcx> Freeze for UnsafetyIsolationCheck<'tcx>
impl<'tcx> !RefUnwindSafe for UnsafetyIsolationCheck<'tcx>
impl<'tcx> !Send for UnsafetyIsolationCheck<'tcx>
impl<'tcx> !Sync for UnsafetyIsolationCheck<'tcx>
impl<'tcx> Unpin for UnsafetyIsolationCheck<'tcx>
impl<'tcx> !UnwindSafe for UnsafetyIsolationCheck<'tcx>
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