Skip to content
Snippets Groups Projects
Commit d63dfdbe authored by Cyril Moineau's avatar Cyril Moineau
Browse files

Merge branch 'main' of https://git-dscin.intra.cea.fr/aidge/aidge_core into main

parents 214cc8a2 db01f456
No related branches found
No related tags found
No related merge requests found
......@@ -575,13 +575,14 @@ bool Aidge::GraphView::replaceWith(std::set<std::shared_ptr<Node>> newNodes) {
for (auto& nodePtr : copyNode) { nodePtr->resetConnections(true); }
// copy output connections
for (IONb_t o = 0; o < previousOutputNode->nbOutputs(); ++o) {
auto outputPairs = copyOutputs[o];
for (const auto& onePair : outputPairs) {
newOutputNode->addChild(onePair.first, o, onePair.second);
if (newOutputNode) {
for (IONb_t o = 0; o < previousOutputNode->nbOutputs(); ++o) {
auto outputPairs = copyOutputs[o];
for (const auto& onePair : outputPairs) {
newOutputNode->addChild(onePair.first, o, onePair.second);
}
}
}
// insert new Nodes in the right GraphViews
for (auto& graphPtr : commonGraphViews) {
graphPtr->add(newNodes, false);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment