Skip to main content

add_metadata_node

Function add_metadata_node 

Source
pub fn add_metadata_node(
    ctx: &Context,
    op: Ptr<Operation>,
    node: MdNodeAttr,
) -> Result<MdNodeId>
Expand description

Add node to the metadata table of the module enclosing op, creating the table if the module doesn’t have one yet, and get the MdNodeId to refer to it by.

A non-distinct node already in the table isn’t added again.