diff options
Diffstat (limited to 'impl/Operator.hpp')
-rw-r--r-- | impl/Operator.hpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/impl/Operator.hpp b/impl/Operator.hpp index dee7f47..80bc8b2 100644 --- a/impl/Operator.hpp +++ b/impl/Operator.hpp @@ -38,6 +38,7 @@ struct Maximum : public Operator<T> { ++it) { T temporary = (**it)(assignment, visited); value = (temporary < value ? value : temporary); + if (value == infinity<T>()) break; } return value; } @@ -51,6 +52,7 @@ struct Minimum : public Operator<T> { ++it) { T temporary = (**it)(assignment, visited); value = (temporary < value ? temporary : value); + if (value == -infinity<T>()) break; } return value; } |