primitives/one: Corrected return type of '+' and '-' operators
This commit is contained in:
@ -42,25 +42,25 @@ public:
|
||||
};
|
||||
|
||||
template<class Type>
|
||||
inline const Type& operator+(const Type& t, const one&)
|
||||
inline Type operator+(const Type& t, const one&)
|
||||
{
|
||||
return t + 1;
|
||||
}
|
||||
|
||||
template<class Type>
|
||||
inline const Type& operator+(const one&, const Type& t)
|
||||
inline Type operator+(const one&, const Type& t)
|
||||
{
|
||||
return 1 + t;
|
||||
}
|
||||
|
||||
template<class Type>
|
||||
inline const Type& operator-(const Type& t, const one&)
|
||||
inline Type operator-(const Type& t, const one&)
|
||||
{
|
||||
return t - 1;
|
||||
}
|
||||
|
||||
template<class Type>
|
||||
inline const Type& operator-(const one&, const Type& t)
|
||||
inline Type operator-(const one&, const Type& t)
|
||||
{
|
||||
return 1 - t;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user