diff --git a/include/SFML/System/Vector2.inl b/include/SFML/System/Vector2.inl index e00df846..6ffaef97 100644 --- a/include/SFML/System/Vector2.inl +++ b/include/SFML/System/Vector2.inl @@ -67,7 +67,7 @@ T Vector2::length() const template constexpr T Vector2::lengthSq() const { - return this->dot(*this); + return dot(*this); } @@ -90,7 +90,7 @@ Angle Vector2::angleTo(const Vector2& rhs) const assert(*this != Vector2()); assert(rhs != Vector2()); - return radians(std::atan2(this->cross(rhs), this->dot(rhs))); + return radians(std::atan2(cross(rhs), dot(rhs))); } @@ -129,7 +129,7 @@ constexpr Vector2 Vector2::projectedOnto(const Vector2& axis) const static_assert(std::is_floating_point_v, "Vector2::projectedOnto() is only supported for floating point types"); assert(axis != Vector2()); - return this->dot(axis) / axis.lengthSq() * axis; + return dot(axis) / axis.lengthSq() * axis; }