./
Coverage:
low: ≥ 0%
medium: ≥ 75.0%
high: ≥ 90.0%
Lines:
0 / 3
0.0%
Branches:
0 / 4
0.0%
Functions:
0 / 1
0.0%

libs/base/src/eu/base/size.h
Line Branch Exec Source
1 #pragma once
2
3 namespace eu
4 {
5 /** \addtogroup math
6 * @{
7 */
8
9 /// a size
10 struct Size
11 {
12 int width;
13 int height;
14 };
15 ✗ constexpr bool operator==(const Size& lhs, const Size& rhs)
16 {
17 ✗ return lhs.width == rhs.width
18
0/4
✗ Branch 2 → 3 not taken.
✗ Branch 2 → 5 not taken.
✗ Branch 3 → 4 not taken.
✗ Branch 3 → 5 not taken.
✗ && lhs.height == rhs.height;
19 }
20
21 /// converts a 2d unit vector to a string, prefer fmt
22 std::string string_from(const Size& v);
23
24 /** @}*/
25 }
26
27 ADD_DEFAULT_FORMATTER(eu::Size, std::string, eu::string_from);
28