pattern: Fixed memory leak when using conditionals in structs

This commit is contained in:
WerWolv
2022-01-22 13:44:00 +01:00
parent 768e74d9d3
commit d69eb440d8
3 changed files with 212 additions and 195 deletions

View File

@@ -175,7 +175,7 @@ namespace hex::pl {
}
} else {
auto newPatterns = node->createPatterns(this);
patterns.insert(patterns.end(), newPatterns.begin(), newPatterns.end());
std::copy(newPatterns.begin(), newPatterns.end(), std::back_inserter(patterns));
}
}