Fix: check starting_age <= age, instead of starting_age < age. Otherwise we can get into an infinite loop.

This commit is contained in:
Twan van Laarhoven
2020-05-07 02:56:43 +02:00
parent 26f35893ae
commit 360f8d71ad
2 changed files with 3 additions and 1 deletions
+2
View File
@@ -40,6 +40,8 @@ public:
/// Compare two ages, smaller means earlier
inline bool operator < (Age a) const { return age < a.age; }
/// Compare two ages
inline bool operator <= (Age a) const { return age <= a.age; }
/// Compare two ages
inline bool operator == (Age a) const { return age == a.age; }
/// A number corresponding to the age