bool setDistinctRoseTops(RoseGraph &g, NGHolder &h1, const NGHolder &h2,
const deque<RoseVertex> &verts1) {
map<u32, u32> top_mapping;
- if (!setDistinctTops(h1, h2, top_mapping)) {
- return false;
- }
+
+ setDistinctTops(h1, h2, top_mapping);
if (top_mapping.empty()) {
return true; // No remapping necessary.
bool setDistinctSuffixTops(RoseGraph &g, NGHolder &h1, const NGHolder &h2,
const deque<RoseVertex> &verts1) {
map<u32, u32> top_mapping;
- if (!setDistinctTops(h1, h2, top_mapping)) {
- return false;
- }
+ setDistinctTops(h1, h2, top_mapping);
if (top_mapping.empty()) {
return true; // No remapping necessary.
}
}
- if (!setDistinctRoseTops(g, victim, *r1.graph(), verts2)) {
- DEBUG_PRINTF("can't set distinct tops\n");
- continue; // next h2
- }
+ setDistinctRoseTops(g, victim, *r1.graph(), verts2);
assert(victim.kind == r1.graph()->kind);
assert(!generates_callbacks(*r1.graph()));
old_tops[v] = g[v].suffix.top;
}
- if (!setDistinctSuffixTops(g, victim, *s1.graph(), verts2)) {
- DEBUG_PRINTF("can't set distinct tops\n");
- continue; // next h2
- }
+ setDistinctSuffixTops(g, victim, *s1.graph(), verts2);
if (!mergeNfaPair(victim, *s1.graph(), &tbi.rm, tbi.cc)) {
DEBUG_PRINTF("merge failed\n");