#[non_exhaustive]pub struct ElementCountReport {
pub total: usize,
pub rules: Vec<ElementCountNode>,
}Expand description
A structured element-count report for one canonical Workshop program.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.total: usizeThe sum of all rule counts.
rules: Vec<ElementCountNode>Rule nodes in canonical source/WIR order.
Implementations§
Source§impl ElementCountReport
impl ElementCountReport
Sourcepub fn rule_counts(&self) -> impl Iterator<Item = (&str, usize)>
pub fn rule_counts(&self) -> impl Iterator<Item = (&str, usize)>
Return the per-rule total in source/WIR order.
Trait Implementations§
Source§impl Clone for ElementCountReport
impl Clone for ElementCountReport
Auto Trait Implementations§
impl Freeze for ElementCountReport
impl RefUnwindSafe for ElementCountReport
impl Send for ElementCountReport
impl Sync for ElementCountReport
impl Unpin for ElementCountReport
impl UnsafeUnpin for ElementCountReport
impl UnwindSafe for ElementCountReport
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