We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bb159af commit 3974030Copy full SHA for 3974030
1 file changed
sbg/map.cpp
@@ -171,13 +171,17 @@ Set Map::lessImage(const Map& other) const
171
172
Map Map::minAdj(const Map& other) const
173
{
174
- Set result_domain = image(_domain.intersection(other._domain));
+ Set this_other_dom = _domain.intersection(other._domain);
175
+ if (this_other_dom.isEmpty()) {
176
+ return Map{};
177
+ }
178
179
+ Set result_domain = image(this_other_dom);
180
Expression result_expr;
- Set image2 = other.image(result_domain);
181
if (_law.isInjective()) {
182
result_expr = other._law.composition(_law.inverse());
183
} else {
184
+ Set image2 = other.image(this_other_dom);
185
result_expr = Expression{image2.minElem()};
186
}
187
0 commit comments