summaryrefslogtreecommitdiff
path: root/AK/Complex.h
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2022-10-17 00:06:11 +0200
committerLinus Groh <mail@linusgroh.de>2022-12-03 23:52:23 +0000
commitd26aabff0401690d6dd1332558b40f5cb64e4428 (patch)
treefd56d0ab5b672814a1a2fb7b8a92fefb01f24e6f /AK/Complex.h
parent8639d8bc212dcb45aff80405b4b0f6b1ef1087e7 (diff)
downloadserenity-d26aabff0401690d6dd1332558b40f5cb64e4428.zip
Everywhere: Run clang-format
Diffstat (limited to 'AK/Complex.h')
-rw-r--r--AK/Complex.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/AK/Complex.h b/AK/Complex.h
index f2655314cc..ece1770189 100644
--- a/AK/Complex.h
+++ b/AK/Complex.h
@@ -69,7 +69,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T>& operator=(const U& x)
+ constexpr Complex<T>& operator=(U const& x)
{
m_real = x;
m_imag = 0;
@@ -85,7 +85,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator+=(const U& x)
+ constexpr Complex<T> operator+=(U const& x)
{
m_real += x.real();
return *this;
@@ -100,7 +100,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator-=(const U& x)
+ constexpr Complex<T> operator-=(U const& x)
{
m_real -= x.real();
return *this;
@@ -116,7 +116,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator*=(const U& x)
+ constexpr Complex<T> operator*=(U const& x)
{
m_real *= x;
m_imag *= x;
@@ -134,7 +134,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator/=(const U& x)
+ constexpr Complex<T> operator/=(U const& x)
{
m_real /= x;
m_imag /= x;
@@ -150,7 +150,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator+(const U& a)
+ constexpr Complex<T> operator+(U const& a)
{
Complex<T> x = *this;
x += a;
@@ -166,7 +166,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator-(const U& a)
+ constexpr Complex<T> operator-(U const& a)
{
Complex<T> x = *this;
x -= a;
@@ -182,7 +182,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator*(const U& a)
+ constexpr Complex<T> operator*(U const& a)
{
Complex<T> x = *this;
x *= a;
@@ -198,7 +198,7 @@ public:
}
template<AK::Concepts::Arithmetic U>
- constexpr Complex<T> operator/(const U& a)
+ constexpr Complex<T> operator/(U const& a)
{
Complex<T> x = *this;
x /= a;
@@ -228,7 +228,7 @@ private:
// reverse associativity operators for scalars
template<AK::Concepts::Arithmetic T, AK::Concepts::Arithmetic U>
-constexpr Complex<T> operator+(const U& b, Complex<T> const& a)
+constexpr Complex<T> operator+(U const& b, Complex<T> const& a)
{
Complex<T> x = a;
x += b;
@@ -236,7 +236,7 @@ constexpr Complex<T> operator+(const U& b, Complex<T> const& a)
}
template<AK::Concepts::Arithmetic T, AK::Concepts::Arithmetic U>
-constexpr Complex<T> operator-(const U& b, Complex<T> const& a)
+constexpr Complex<T> operator-(U const& b, Complex<T> const& a)
{
Complex<T> x = a;
x -= b;
@@ -244,7 +244,7 @@ constexpr Complex<T> operator-(const U& b, Complex<T> const& a)
}
template<AK::Concepts::Arithmetic T, AK::Concepts::Arithmetic U>
-constexpr Complex<T> operator*(const U& b, Complex<T> const& a)
+constexpr Complex<T> operator*(U const& b, Complex<T> const& a)
{
Complex<T> x = a;
x *= b;
@@ -252,7 +252,7 @@ constexpr Complex<T> operator*(const U& b, Complex<T> const& a)
}
template<AK::Concepts::Arithmetic T, AK::Concepts::Arithmetic U>
-constexpr Complex<T> operator/(const U& b, Complex<T> const& a)
+constexpr Complex<T> operator/(U const& b, Complex<T> const& a)
{
Complex<T> x = a;
x /= b;