Selaa lähdekoodia

Extend 'NumericContainedValueBase::qualifies' to allow types with equal bounds

Ole Krüger 10 vuotta sitten
vanhempi
commit
9154622665
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      lib/luwra/types.hpp

+ 2 - 2
lib/luwra/types.hpp

@@ -136,8 +136,8 @@ namespace internal {
 		static constexpr
 		bool qualifies =
 			// TODO: Remove warning about comparsion between signed and unsigned integers
-			std::numeric_limits<I>::max() < std::numeric_limits<B>::max()
-			&& std::numeric_limits<I>::min() > std::numeric_limits<B>::min();
+			std::numeric_limits<I>::max() <= std::numeric_limits<B>::max()
+			&& std::numeric_limits<I>::min() >= std::numeric_limits<B>::min();
 
 		static inline
 		I read(State* state, int index) {