mirror of
https://github.com/revng/revng
synced 2026-06-21 14:07:57 +00:00
DLATypeSystem: add assertion on mergeNodes
The mergeNodes API is not guaranteed to work properly if the 2 merged nodes are the same. This commit adds an assertion to rule this situation out.
This commit is contained in:
@@ -471,6 +471,7 @@ inline void
|
||||
LayoutTypeSystem::mergeNodes(LayoutTypeSystemNode *From,
|
||||
LayoutTypeSystemNode *Into,
|
||||
llvm::SmallSet<LayoutTypePtr, 2> *IntoTypePtrs) {
|
||||
revng_assert(From != Into);
|
||||
revng_log(MergeLog, "Merging: " << From << " Into: " << Into);
|
||||
auto LayoutIt = Layouts.find(From);
|
||||
revng_assert(LayoutIt != Layouts.end());
|
||||
|
||||
Reference in New Issue
Block a user