mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-15 22:28:10 +08:00
Make Node::layout non-optional, defaulting to a shared empty layout
This commit is contained in:
@@ -1702,8 +1702,8 @@ pub(crate) fn generate_node_impl(crate_ident: &CrateIdent, parsed: &ParsedNodeFn
|
||||
|
||||
let record_layout_impl = match record.is_some() || routing.is_some() || flip || opaque {
|
||||
true => quote! {
|
||||
fn layout(&self) -> Option<&#core_types::record::Layout> {
|
||||
Some(&self.__layout)
|
||||
fn layout(&self) -> &#core_types::record::Layout {
|
||||
&self.__layout
|
||||
}
|
||||
},
|
||||
false => quote!(),
|
||||
|
||||
Reference in New Issue
Block a user