Mateusz Pusz
7ce8d695b1
test: std::complex-based quantities tests added
2024-09-17 12:48:13 -06:00
Mateusz Pusz
0670fbdd9f
feat: value_cast<Representation, Unit>() complementary conversion function added
2024-09-13 21:38:59 +02:00
Mateusz Pusz
3d39472f46
test: unit tests for creating a quantity from a volatile variable
2024-09-06 18:07:33 +02:00
Mateusz Pusz
1570bda905
fix: quantity scaling between different prefixes improved
...
Resolves #608
2024-09-06 12:28:11 +02:00
Mateusz Pusz
2e840cfdb4
refactor: Repetitive inline constexpr removed as no longer needed
...
Not needed anymore as stated in cplusplus/draft#4601
2024-09-05 08:43:36 +02:00
Chip Hogg
3a6fac9858
Move tests to runtime
2024-07-24 20:04:15 -04:00
Chip Hogg
f6696e8f68
Fix formatting
2024-07-24 19:48:05 -04:00
Chip Hogg
7e894788d7
Compute values for rational magnitude powers
...
Since this will only ever be done at compile time (as guaranteed by
using `consteval`), we can afford to prioritize precision over speed.
To compute an Nth root, we simply do a binary search over representable
floating point numbers, looking for the number whose Nth power most
closely matches the original number.
Fixes #494 . We have included a test case reproducing the original
problem exactly. All tests use "within 4 ULPs" as the criterion, which
is (I believe) equivalent to the googletest `EXPECT_DOUBLE_EQ`
criterion.
2024-07-24 10:31:44 -04:00
Mateusz Pusz
b870b85c25
feat: import std; support added
...
Resolves #595
2024-07-16 17:36:00 +02:00
Mateusz Pusz
c57142c18a
fix: common_type_t with std::chrono::seconds unit test removed
2024-07-14 22:22:39 +02:00
Mateusz Pusz
d84a2beae5
fix: common_type_t unit tests fixed
2024-07-14 22:12:25 +02:00
Mateusz Pusz
fcc16ae282
feat: convertibility of a quantity with a unit one with the raw value added
...
Resolves #553
2024-07-14 18:31:11 +02:00
Mateusz Pusz
adbc77432e
feat: all tags in the expression templates are now ordered by the type names
...
Resolves #499
2024-07-12 17:48:38 +02:00
Mateusz Pusz
2cff579650
feat: representation type template parameter added to value convertion functions
...
Resolves #588
2024-07-04 22:05:40 +01:00
Mateusz Pusz
2adc9344ea
refactor: some TODO comment addressed or removed
2024-06-01 13:36:22 +02:00
Mateusz Pusz
ec287664ee
refactor: some TODO comments resolved
2024-05-31 21:07:42 +02:00
Mateusz Pusz
cd36e6f974
feat: freestanding support added
...
Resolves #564 , #565 , and #556
2024-05-30 19:50:02 +02:00
Yves Delley
09c7b059c7
review suggestions
...
Co-authored-by: Mateusz Pusz <mateusz.pusz@gmail.com >
2024-05-10 21:38:40 +02:00
Yves Delley
c2fa8a9000
avoid using a function for the lvalue test
2024-05-10 21:13:21 +02:00
Yves Delley
d03f9c17a3
fix constexpr and format
2024-05-10 20:15:15 +02:00
Yves Delley
b119abed56
add test for lvalue references in quantity_cast
2024-05-10 20:01:35 +02:00
Mateusz Pusz
54d144d112
refactor: workarounds for clang-tidy-18
2024-05-08 14:46:04 +02:00
Mateusz Pusz
75f719add7
refactor: code refactored to comply with clang-tidy
2024-05-08 11:12:38 +02:00
Mateusz Pusz
8ea346be1c
refactor: 💥 header files with the entire system definitions moved up in the directory tree
2024-04-25 16:34:11 +02:00
Mateusz Pusz
c066104af7
refactor: 💥 framework.h introduced + IWYU
2024-04-24 21:09:29 +02:00
Mateusz Pusz
15389107d4
fix: dependencies on cstdint header fixed
2024-04-23 08:59:14 +02:00
Mateusz Pusz
5ca9168381
feat: proper exports implemented for C++ modules
2024-02-23 21:09:17 +01:00
Mateusz Pusz
25a4c7c128
fix: quantity_test compilation fixed
2024-02-05 19:32:38 +01:00
Mateusz Pusz
d036af5647
fix: compilation errors after the last commit fixed
2024-01-19 11:09:29 +01:00
Mateusz Pusz
0eaf6e2e56
refactor: modules support redesigned
2024-01-06 08:51:01 +01:00