Struct naga::valid::function::BlockContext
source · struct BlockContext<'a> {
abilities: ControlFlowAbility,
info: &'a FunctionInfo,
expressions: &'a Arena<Expression>,
types: &'a UniqueArena<Type>,
local_vars: &'a Arena<LocalVariable>,
global_vars: &'a Arena<GlobalVariable>,
functions: &'a Arena<Function>,
special_types: &'a SpecialTypes,
prev_infos: &'a [FunctionInfo],
return_type: Option<Handle<Type>>,
}
Fields§
§abilities: ControlFlowAbility
§info: &'a FunctionInfo
§expressions: &'a Arena<Expression>
§types: &'a UniqueArena<Type>
§local_vars: &'a Arena<LocalVariable>
§global_vars: &'a Arena<GlobalVariable>
§functions: &'a Arena<Function>
§special_types: &'a SpecialTypes
§prev_infos: &'a [FunctionInfo]
§return_type: Option<Handle<Type>>
Implementations§
source§impl<'a> BlockContext<'a>
impl<'a> BlockContext<'a>
fn new( fun: &'a Function, module: &'a Module, info: &'a FunctionInfo, prev_infos: &'a [FunctionInfo], ) -> Self
const fn with_abilities(&self, abilities: ControlFlowAbility) -> Self
fn get_expression(&self, handle: Handle<Expression>) -> &'a Expression
fn resolve_type_impl( &self, handle: Handle<Expression>, valid_expressions: &HandleSet<Expression>, ) -> Result<&TypeInner, WithSpan<ExpressionError>>
fn resolve_type( &self, handle: Handle<Expression>, valid_expressions: &HandleSet<Expression>, ) -> Result<&TypeInner, WithSpan<FunctionError>>
fn resolve_pointer_type(&self, handle: Handle<Expression>) -> &TypeInner
Auto Trait Implementations§
impl<'a> Freeze for BlockContext<'a>
impl<'a> RefUnwindSafe for BlockContext<'a>
impl<'a> Send for BlockContext<'a>
impl<'a> Sync for BlockContext<'a>
impl<'a> Unpin for BlockContext<'a>
impl<'a> UnwindSafe for BlockContext<'a>
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