-- | Render the given op if it hasn't been rendered already, and return its
-- name.
getOrAddOp :: OpDef -> Build NodeName
getOrAddOp o = do
    pending <- getPendingNode o
    uses renderedNodes (Map.lookup pending) >>= \case
        Just n -> return $ NodeName $ n ^. name
        Nothing -> addNewOpFromPending pending
getOrAddOp :: OpDef -> Build NodeName
getOrAddOp o = do
    pending <- getPendingNode o
    uses renderedNodes (Map.lookup pending) >>= \case
        Just n -> return $ NodeName $ n ^. name
        Nothing -> addNewOpFromPending pending
getOrAddOp o = do
    pending <- getPendingNode o
    uses renderedNodes (Map.lookup pending) >>= \case
        Just n -> return $ NodeName $ n ^. name
        Nothing -> addNewOpFromPending pending