GlobalContext

Trait GlobalContext 

Source
pub trait GlobalContext<'a>: Sized {
    // Required method
    fn is_global_reference(&self, reference: &IdentifierReference<'a>) -> bool;

    // Provided methods
    fn is_global_expr(&self, name: &str, expr: &Expression<'a>) -> bool { ... }
    fn get_constant_value_for_reference_id(
        &self,
        _reference_id: ReferenceId,
    ) -> Option<ConstantValue<'a>> { ... }
}

Required Methods§

Source

fn is_global_reference(&self, reference: &IdentifierReference<'a>) -> bool

Whether the reference is a global reference.

Provided Methods§

Source

fn is_global_expr(&self, name: &str, expr: &Expression<'a>) -> bool

Source

fn get_constant_value_for_reference_id( &self, _reference_id: ReferenceId, ) -> Option<ConstantValue<'a>>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§