(svn r11691) -Codechange: move+rename helpers.hpp and only include it when it is really needed.
This commit is contained in:
@@ -211,4 +211,16 @@ template<typename T> static inline bool IsInsideMM(const T x, const uint min, co
|
||||
return (uint)(x - min) < (max - min);
|
||||
}
|
||||
|
||||
/**
|
||||
* Type safe swap operation
|
||||
* @param a variable to swap with b
|
||||
* @param b variable to swap with a
|
||||
*/
|
||||
template<typename T> void Swap(T& a, T& b)
|
||||
{
|
||||
T t = a;
|
||||
a = b;
|
||||
b = t;
|
||||
}
|
||||
|
||||
#endif /* MATH_FUNC_HPP */
|
||||
|
Reference in New Issue
Block a user