Enum rsass::ScopeRef [−][src]
Expand description
A static or dynamic scope referece.
This dereferences to a Scope.
Variants
Builtin(&'static Scope)
Tuple Fields
0: &'static Scope
The builtin scopes in rsass is static.
Dynamic(Arc<Scope>)
All other scopes are dynamic. This uses Arc reference counting.
Implementations
Create a new global scope.
A “global” scope is just a scope that have no parent. There will be multiple global scopes existing during the evaluation of a single sass file.
Create a new subscope of a given parent with selectors.
Methods from Deref<Target = Scope>
Define a module in the scope.
This is used by the @use
statement.
Get a module.
This is used when refering to a function or variable with namespace.name notation.
Get the format used in this scope.
Define a variable with a value.
The $
sign is not included in name
.
Define a variable in the global scope that is an ultimate parent of this scope.
Define multiple names from a value that is a list. Special case: in names is a single name, value is used directly.
Get the Value for a variable.
Get the value for a variable (or an error).
Copy a set of local variables to a temporary holder
Restore a set of local variables from a temporary holder
Get the global Value for a variable.
Get a mixin by name.
Returns the formal args and the body of the mixin.
Define a mixin.
Define a function.
Get a function by name.
Get the selectors active for this scope.
Get the functions of this scope as a Value::Map
.
Get the variables of this scope as a Value::Map
.
Get the forward scope for this scope.
Create a new one if necessary.
Get the forward scope for this scope.
Create a new one if necessary.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for ScopeRef
impl UnwindSafe for ScopeRef
Blanket Implementations
Mutably borrows from an owned value. Read more