track_refcell_drop

Function track_refcell_drop 

Source
pub fn track_refcell_drop(borrow_id: &str, location: &str)
Expand description

Track RefCell borrow drop (when Ref/RefMut is dropped).

Records a RefCellDrop event. Call this when a RefCell guard goes out of scope.

§Arguments

  • borrow_id - The identifier used when the borrow was created
  • location - Source location where the drop occurs

§Examples

use std::cell::RefCell;

let cell = track_refcell_new("cell", RefCell::new(42));
{
    let guard = track_refcell_borrow("b1", "cell", "main.rs:10", cell.borrow());
    // use guard...
    track_refcell_drop("b1", "main.rs:12");
}