Struct naga::Function[][src]

pub struct Function {
    pub name: Option<String>,
    pub arguments: Vec<FunctionArgument>,
    pub result: Option<FunctionResult>,
    pub local_variables: Arena<LocalVariable>,
    pub expressions: Arena<Expression>,
    pub named_expressions: FastHashMap<Handle<Expression>, String>,
    pub body: Block,
}
Expand description

A function defined in the module.

Fields

name: Option<String>

Name of the function, if any.

arguments: Vec<FunctionArgument>

Information about function argument.

result: Option<FunctionResult>

The result of this function, if any.

local_variables: Arena<LocalVariable>

Local variables defined and used in the function.

expressions: Arena<Expression>

Expressions used inside this function.

named_expressions: FastHashMap<Handle<Expression>, String>

Map of expressions that have associated variable names

body: Block

Block of instructions comprising the body of the function.

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.