pub struct RegionEvent<Id, Key> {
pub kind: EventKind,
pub node: Id,
pub key: Key,
}Expand description
区域扫描事件(使用索引的原子):语句子树遍历中的一次读/写/遮蔽。
node 指向承载名字的节点(Use→VarRef;Write→赋值目标 VarRef 或
声明节点;Shadow→VarDecl/ForEach/Catch 绑定节点),名字由
Lang::var_name(node) 读取——与 scan_region 原递归的判定一致。
Fields§
§kind: EventKind§node: Id§key: Key事件承载者的名字键(语言侧等价类:Java=u32 intern id)—— 事件构建时预存,查询侧比较为整数等值,免 var_name/memcmp。
Trait Implementations§
impl<Id: Copy, Key: Copy> Copy for RegionEvent<Id, Key>
Auto Trait Implementations§
impl<Id, Key> Freeze for RegionEvent<Id, Key>
impl<Id, Key> RefUnwindSafe for RegionEvent<Id, Key>where
Id: RefUnwindSafe,
Key: RefUnwindSafe,
impl<Id, Key> Send for RegionEvent<Id, Key>
impl<Id, Key> Sync for RegionEvent<Id, Key>
impl<Id, Key> Unpin for RegionEvent<Id, Key>
impl<Id, Key> UnsafeUnpin for RegionEvent<Id, Key>where
Id: UnsafeUnpin,
Key: UnsafeUnpin,
impl<Id, Key> UnwindSafe for RegionEvent<Id, Key>where
Id: UnwindSafe,
Key: UnwindSafe,
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