Mateusz Pusz
8c9986dec8
Merge branch 'master' of github.com:mpusz/units
2020-09-08 13:23:36 +02:00
Mateusz Pusz
d8e8a94c5b
style: comment changed for has_symbol
2020-09-08 13:13:04 +02:00
Mateusz Pusz
4bb51586dc
refactor: got rid of gcc-9 backlog
...
BREAKING CHANGE: gcc-9.3 no longer supported
2020-09-08 13:09:34 +02:00
Mateusz Pusz
7ed4f19ef3
refactor: ♻️ exp_* operations on exponents renamed to `exponent_*
2020-09-08 11:10:33 +02:00
Mateusz Pusz
563b358d5e
feat!: 💥 dimensionless quantities refactored
...
Dimensionless quantities are now represented by quantity types rather
than by plain representation types. Only dimensionless quantities with
`unitless` unit are implicitly convertible from representation types.
`units::exp()` now is a function doing std::exp() on a representation
type (previous `units::exp` class template was renamed to
`units::exponent`).
BREAKING_CHANGE: gcc-9.3 support removed
BREAKING_CHANGE: `exp` and `Exp` renamed to `exponent` and `Exponent`
Resolves #27
Resolves #42
2020-09-08 11:02:16 +02:00
Johel Ernesto Guerrero Peña
8fc0c254a6
style: add TODO comment for when to update
2020-09-08 09:42:27 +02:00
Johel Ernesto Guerrero Peña
7c00b196a3
refactor: simplify is_derived_from_specialization_of
2020-09-08 09:42:27 +02:00
Johel Ernesto Guerrero Peña
e30aa9c4a0
refactor: simplify is_specialization_of
2020-09-08 09:42:27 +02:00
Johel Ernesto Guerrero Peña
db041061e0
chore: iwyu
2020-09-08 09:42:27 +02:00
Johel Ernesto Guerrero Peña
46761ea2f7
refactor: *_instantation_of to *_specialization_of
2020-09-06 22:52:01 +02:00
Johel Ernesto Guerrero Peña
ca1867c9b2
refactor!: pow functions as detail
2020-09-06 09:45:24 +02:00
Mateusz Pusz
b318e8d039
VS2019 support added
2020-09-04 23:06:57 +02:00
Johel Ernesto Guerrero Peña
1c64e9f4a2
refactor: remove Expects macro
2020-08-24 11:35:58 +02:00
Mateusz Pusz
653a090a8a
unknown_dimension simplified
2020-08-18 14:27:33 +02:00
Mateusz Pusz
d452ec7df5
gsl header replaced with gsl_assert
2020-08-17 21:33:23 +02:00
Mateusz Pusz
51b6d2f974
ms-gsl dependency added to handle Expects ( resolves #132 )
2020-08-17 20:27:45 +02:00
Johel Ernesto Guerrero Peña
67b1c499d1
refactor: avoid always false comparison
2020-08-16 13:32:30 +02:00
Mateusz Pusz
9f94a73bba
Custom is_same implementation added
2020-06-29 20:30:59 +02:00
Mateusz Pusz
7eccef78a9
is_instantiation renamed to is_instantiation_of
2020-06-29 20:28:10 +02:00
Mateusz Pusz
d171f5451e
NTTP ratio support added ( resolves #49 )
2020-06-27 19:15:46 +02:00
Mateusz Pusz
f55eacfa85
glide_computer example added
2020-06-21 10:37:45 +02:00
Johel Ernesto Guerrero Peña
75119eef3f
feat: quantity_point
2020-06-17 15:31:22 +02:00
Mateusz Pusz
10f93b5386
Compilation on gcc-9 fixed
2020-05-28 20:45:15 +02:00
Mateusz Pusz
86b9177816
Specialize common_type to satisfy comparison concepts ( resolves #113 )
2020-05-28 20:19:05 +02:00
Mateusz Pusz
77a94b6d73
Ccompilation error fixed on gcc-9
2020-05-28 13:37:20 +02:00
Mateusz Pusz
e58c8054bc
Doxygen documentation added
2020-05-13 15:33:29 +02:00
Mateusz Pusz
ce301748dd
Velocity renamed to Speed ( resolves #103 )
2020-05-10 17:31:47 +02:00
Mateusz Pusz
d19825e14c
Numeric concepts removed from repo (no longer used)
2020-03-28 12:08:37 +01:00
Mateusz Pusz
f75a69da9a
Direct namespace usage removed from fixed_string
2020-03-27 15:21:42 +01:00
Ramzi Sabra
36bee5a8c3
fixed dot product symbol
2020-03-27 10:03:59 +01:00
Ramzi Sabra
e0263c554d
added ASCII character validation; added ASCII-only superscripts, scientific notation, dot product
2020-03-27 10:03:59 +01:00
Ramzi Sabra
f6d9a1cbda
removed c_str(), size(), operator<< abstractions from basic_symbol_text
2020-03-27 10:03:59 +01:00
Ramzi Sabra
e9272ac108
added ASCII-only format output support
2020-03-27 10:03:59 +01:00
Mateusz Pusz
034f239f96
PrefixType renamed to PrefixFamily + units hierarchy PNG fixed
2020-03-19 14:44:56 +01:00
Mateusz Pusz
c33f6f2d59
ostream width, align and fill added
2020-03-19 09:23:27 +01:00
Mateusz Pusz
d2e49b25f7
Clang uses the Ranges-v3 concepts
2020-03-17 17:12:01 +01:00
Mateusz Pusz
0c02f94d29
Printing of uknown non-coherent units fixed
2020-02-24 20:45:47 +01:00
Mateusz Pusz
e7756bf4eb
Printing order of base units according to the recipe fixed
2020-02-24 15:18:37 +01:00
Mateusz Pusz
0eb2f404be
clang-format applied to type_list
2020-02-24 15:17:03 +01:00
Mateusz Pusz
c745bebffd
type_list_join added
2020-02-24 15:15:46 +01:00
Oliver Schönrock
ef862c9f69
include what we use and use system header syntax
...
don't show 10^0 when den != 0
2020-02-22 22:08:36 +01:00
Oliver Schönrock
424f0512c1
hack fix?!
2020-02-22 22:08:36 +01:00
Mateusz Pusz
0c89df3980
unknown_unit renamed to unknown_coherent_unit
2020-02-22 09:37:40 +01:00
Oliver Schönrock
834d1fa09d
extending the range of operator* for incoherent units with large num/den
...
this improves the situation for #55 (doesn't solve it outright)
motivating examples which now work are:
1q_mi * 1q_mi * 1q_mi
1q_au * 1q_au
tests added and docs updated
2020-02-20 23:46:55 +01:00
Oliver Schönrock
39a2c2de0e
employing more mathemtaically correct ratio_gcd calc (for common ratio)
...
really finds the maximum common ration as opposed to previous algo which
simplified on the exp part of the ratio by using std::min
most of new code credit to Conor Williams
discussion and additional doc here:
https://github.com/mpusz/units/issues/62#issuecomment-588152833
test case was 1yd + 1in = 37in => added as a test
commenting out unusued ratio_add and its tests
if to be reintroduced, should also use the new gcd routines
additonal change was required to check in `safe_divisible` concept
den=1 is not sufficient anymore. reusing new gcd routines
moved ratio nomalize and new gcd routines into new, separate bits/ratio_maths.h
this resolves #62
2020-02-20 19:59:12 +01:00
Oliver Schönrock
0566cc631d
implementing units::ratio_add and tests
...
not yet used in src/include/units/bits/dim_consolidate.h
because it breaks and cascades (due to new exponent we think)
2020-02-16 14:53:06 +01:00
Mateusz Pusz
d832b3a462
basic_fixed_string op== improved
2020-02-12 09:55:28 +01:00
Mateusz Pusz
3be8ee921e
Starship improvements after the latest gcc fixes
2020-02-12 09:48:04 +01:00
Mateusz Pusz
037503cbc6
deduced_unit fixed + unit test for mass unit added
2020-02-10 20:35:32 +01:00
Mateusz Pusz
78350ed94b
same_as remplaced with is_same_v in if constexpr
2020-02-08 20:11:20 +01:00