pub struct OwnedScope {
pub namespace: Option<String>,
pub class_name: Option<String>,
pub function_name: Option<String>,
}Expand description
Lexical scope context for owned AST traversal.
Like crate::visitor::Scope but uses Option<String> instead of
Option<&str> so the owned visitor has no lifetime parameters.
Fields§
§namespace: Option<String>Current namespace, or None for the global namespace.
class_name: Option<String>Name of the immediately enclosing class-like declaration, or None.
function_name: Option<String>Name of the immediately enclosing named function or method, or None.
Trait Implementations§
Source§impl Clone for OwnedScope
impl Clone for OwnedScope
Source§fn clone(&self) -> OwnedScope
fn clone(&self) -> OwnedScope
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OwnedScope
impl Debug for OwnedScope
Source§impl Default for OwnedScope
impl Default for OwnedScope
Source§fn default() -> OwnedScope
fn default() -> OwnedScope
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for OwnedScope
impl RefUnwindSafe for OwnedScope
impl Send for OwnedScope
impl Sync for OwnedScope
impl Unpin for OwnedScope
impl UnsafeUnpin for OwnedScope
impl UnwindSafe for OwnedScope
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