Skip to main content

Export

Enum Export 

Source
pub enum Export {
    Class {
        symbol: Symbol,
        class_id: Option<ClassId>,
    },
    Function {
        symbol: Symbol,
        function_id: Option<FunctionId>,
    },
    Macro {
        symbol: Symbol,
        macro_id: Option<MacroId>,
    },
    Shape {
        symbol: Symbol,
        shape_id: Option<ShapeId>,
    },
    Codec {
        symbol: Symbol,
        codec_id: Option<CodecId>,
    },
    NumberDomain {
        symbol: Symbol,
        number_domain_id: Option<NumberDomainId>,
    },
    Value {
        symbol: Symbol,
    },
    Site {
        symbol: Symbol,
        runtime_id: Option<RuntimeId>,
    },
}
Expand description

A single export declared by a library manifest, by export kind.

Variants§

§

Class

A class export; class_id is present once a stable id is reserved.

Fields

§symbol: Symbol

Symbol the class is exported under.

§class_id: Option<ClassId>

Reserved stable class id, if known.

§

Function

A function export; function_id is present once a stable id is reserved.

Fields

§symbol: Symbol

Symbol the function is exported under.

§function_id: Option<FunctionId>

Reserved stable function id, if known.

§

Macro

A macro export; macro_id is present once a stable id is reserved.

Fields

§symbol: Symbol

Symbol the macro is exported under.

§macro_id: Option<MacroId>

Reserved stable macro id, if known.

§

Shape

A shape export; shape_id is present once a stable id is reserved.

Fields

§symbol: Symbol

Symbol the shape is exported under.

§shape_id: Option<ShapeId>

Reserved stable shape id, if known.

§

Codec

A codec export; codec_id is present once a stable id is reserved.

Fields

§symbol: Symbol

Symbol the codec is exported under.

§codec_id: Option<CodecId>

Reserved stable codec id, if known.

§

NumberDomain

A number-domain export; number_domain_id is present once reserved.

Fields

§symbol: Symbol

Symbol the number domain is exported under.

§number_domain_id: Option<NumberDomainId>

Reserved stable number-domain id, if known.

§

Value

A plain value export.

Fields

§symbol: Symbol

Symbol the value is exported under.

§

Site

An opaque placement-site export.

The symbol is the placement key. The kernel stores only the runtime value and stable id; libraries outside the kernel decide whether that value behaves as an evaluation site.

Fields

§symbol: Symbol

Symbol the site is exported under.

§runtime_id: Option<RuntimeId>

Reserved opaque runtime id, if known.

Implementations§

Source§

impl Export

Source

pub fn symbol(&self) -> &Symbol

Returns the symbol this export is declared under.

Source

pub fn kind(&self) -> &'static str

Returns the static kind label for this export.

Source

pub fn kind_symbol(&self) -> ExportKind

Returns this export’s kind as an ExportKind tag.

Source

pub fn declared_record(&self) -> ExportRecord

Builds a Declared ExportRecord for this export.

Trait Implementations§

Source§

impl Clone for Export

Source§

fn clone(&self) -> Export

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Export

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Export

Source§

impl PartialEq for Export

Source§

fn eq(&self, other: &Export) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for Export

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.