#[non_exhaustive]pub struct Modifiers {
pub visibility: Option<Visibility>,
pub set_visibility: Option<Visibility>,
pub is_static: bool,
pub is_abstract: bool,
pub is_final: bool,
pub is_readonly: bool,
}Expand description
The modifiers of a member or promoted parameter. Which flags are valid depends on the node that carries them.
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.visibility: Option<Visibility>Declared visibility, if any.
set_visibility: Option<Visibility>Asymmetric write visibility, e.g. private(set) (PHP 8.4+).
is_static: booltrue for static.
is_abstract: booltrue for abstract.
is_final: booltrue for final.
is_readonly: booltrue for readonly.
Implementations§
Trait Implementations§
impl Copy for Modifiers
impl Eq for Modifiers
impl StructuralPartialEq for Modifiers
Auto Trait Implementations§
impl Freeze for Modifiers
impl RefUnwindSafe for Modifiers
impl Send for Modifiers
impl Sync for Modifiers
impl Unpin for Modifiers
impl UnsafeUnpin for Modifiers
impl UnwindSafe for Modifiers
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