summaryrefslogtreecommitdiffhomepage
path: root/test/const-math.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-10-10 09:09:04 +0200
committerStanislaw Halik <sthalik@misaki.pl>2022-10-10 09:09:04 +0200
commit7e392fae34242c574218aa6dad928faa7b275613 (patch)
treea0ded9cb7f5252fc9e392d604e67e22255d8078a /test/const-math.cpp
parentcf6c5668f1d41a0fe02f97351a522ccfb3f245d4 (diff)
a
Diffstat (limited to 'test/const-math.cpp')
-rw-r--r--test/const-math.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/test/const-math.cpp b/test/const-math.cpp
index 1d07d08f..afb42bf3 100644
--- a/test/const-math.cpp
+++ b/test/const-math.cpp
@@ -14,18 +14,18 @@
using namespace Magnum;
using Magnum::Math::Vector;
-template<typename vec, typename f>
+template<typename vec, typename T>
static constexpr void test_float2()
{
- const vec a{(f)1, (f)2}, b{(f)2, (f)3};
+ const vec a{(T)1, (T)2}, b{(T)2, (T)3};
- ASSERT(a[0] == (f)1 && a[1] == (f)2);
- ASSERT(a + b == vec{(f)3, (f)5});
- ASSERT(a - b == vec{(f)-1, (f)-1});
- ASSERT(a * b == vec{(f)2, (f)6});
- ASSERT(b / a == vec{(f)2, (f)1.5});
- ASSERT(b.product() == (f)6);
- ASSERT(b.sum() == (f)5);
+ ASSERT(a[0] == (T)1 && a[1] == (T)2);
+ ASSERT(a + b == vec{(T)3, (T)5});
+ ASSERT(a - b == vec{(T)-1, (T)-1});
+ ASSERT(a * b == vec{(T)2, (T)6});
+ ASSERT(b / a == vec{(T)2, (T)1.5});
+ ASSERT(b.product() == (T)6);
+ ASSERT(b.sum() == (T)5);
}
template<typename ivec>