pub type StructRef<'a> = MaybeImported<&'a Struct, &'a ImportedStruct>;Expand description
A reference to a struct in the document’s scope.
Aliased Type§
pub enum StructRef<'a> {
Local(&'a Struct),
Imported(&'a ImportedStruct),
}Variants§
Local(&'a Struct)
The item is locally defined.
Imported(&'a ImportedStruct)
The item was imported from another document.
Implementations§
Source§impl<'a> StructRef<'a>
impl<'a> StructRef<'a>
Sourcepub fn definition(&self) -> StructDefinition
pub fn definition(&self) -> StructDefinition
Reconstructs the AST definition from the stored green node.