pub enum HeapType<'a> {
    Func,
    Extern,
    Any,
    Eq,
    Data,
    Array,
    I31,
    Index(Index<'a>),
}
Expand description

A heap type for a reference type

Variants

Func

An untyped function reference: funcref. This is part of the reference types proposal.

Extern

A reference to any host value: externref. This is part of the reference types proposal.

Any

A reference to any reference value: anyref. This is part of the GC proposal.

Eq

A reference that has an identity that can be compared: eqref. This is part of the GC proposal.

Data

A reference to a GC object. This is part of the GC proposal.

Array

A reference to a GC array. This is part of the GC proposal.

I31

An unboxed 31-bit integer: i31ref. This may be going away if there is no common supertype of all reference types. Part of the GC proposal.

Index(Index<'a>)

A reference to a function, struct, or array: ref T. This is part of the GC proposal.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Feeds this value into the given Hasher. Read more

Feeds a slice of this type into the given Hasher. Read more

Attempts to parse Self from parser, returning an error if it could not be parsed. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Tests to see whether this token is the first token within the Cursor specified. Read more

Returns a human-readable name of this token to display when generating errors about this token missing. Read more

The same as peek, except it checks the token immediately following the current token. 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

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

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.