Enum ezno_parser::ChainVariable
source · pub enum ChainVariable {
Block(BlockId),
UnderFunction(BlockId, VariableId),
UnderClassMethod(BlockId),
UnderClassConstructor(BlockId),
UnderObjectLiteralMethod,
UnderExpressionFunctionBlock(BlockId, ExpressionId),
UnderArrowFunction(Option<BlockId>),
UnderRhsOfOperation(ExpressionId),
UnderMatchArm(BlockId),
UnderModule(BlockId, SourceId),
SingleStatementOrExpression,
}
Expand description
Could borrow identifiers but most of them are smaller than a pointer so it doesn’t matter =
TODO work out all the use cases for this Currently used for
Variants§
Block(BlockId)
UnderFunction(BlockId, VariableId)
UnderClassMethod(BlockId)
UnderClassConstructor(BlockId)
UnderObjectLiteralMethod
UnderExpressionFunctionBlock(BlockId, ExpressionId)
UnderArrowFunction(Option<BlockId>)
UnderRhsOfOperation(ExpressionId)
UnderMatchArm(BlockId)
UnderModule(BlockId, SourceId)
SingleStatementOrExpression
Implementations§
source§impl ChainVariable
impl ChainVariable
pub fn get_block_id(&self) -> BlockId
Trait Implementations§
source§impl Clone for ChainVariable
impl Clone for ChainVariable
source§fn clone(&self) -> ChainVariable
fn clone(&self) -> ChainVariable
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more