Markus Hofbauer
50b9050d6b
Feat: Overloads for floor and ceil accepting quantities ( #314 )
...
* feat: overloads for floor and ceil accepting quantities
* require same type for dim and rep
* be specific for msvc
2021-11-15 12:23:28 +01:00
Markus Hofbauer
b881b56480
feat: first draft ceil
2021-11-13 16:50:55 +01:00
Markus Hofbauer
e82bfa23a5
Feat: Floor ( #309 )
...
* feat: first draft floor
* apply review feedback and move to desired files
* implement floor considering float types
* reduce code duplication
* apply review feedback and improve docstring
* enable static floor tests for gcc only
* Use recommended feature-test macro
* add floor runtime unittests
* apply review feedback
* make lambda const
2021-11-13 12:17:43 +01:00
Mateusz Pusz
506408a316
fix: fmt_test compilation fixed
2021-11-08 19:05:08 +01:00
Mateusz Pusz
9f95799288
refactor: got rid of FMT_RUNTIME() as it is not the part of C++20
2021-11-08 18:37:37 +01:00
Mateusz Pusz
2333c4b3ea
build: CMake targets generated by Conan updated
2021-11-04 12:09:54 +01:00
Mateusz Pusz
ed1b2d2647
fix: Some MSVC-specific special cases removed
2021-09-23 19:16:44 +02:00
Mateusz Pusz
b1bd4cab2d
feat: std::format support for compliant compilers added
2021-09-20 15:01:58 +02:00
Mateusz Pusz
8740857a47
build: fmt updated to 8.0.1
2021-09-16 20:24:27 +02:00
Mateusz Pusz
8e88f06380
refactor: *deduced_unit renamed to *derived_unit
2021-05-10 15:56:48 +02:00
Mateusz Pusz
2c8c6c2e98
refactor: quantity cration helpers are not opt-out rather than opt-in
...
Resolves #277
2021-05-09 15:52:20 +02:00
Mateusz Pusz
46e1e5e932
refactor: US system renamed to USCS
2021-04-16 12:40:52 +02:00
Mateusz Pusz
70bff31d06
feat: quantity aliases support addded
2021-04-15 19:13:25 +02:00
Mateusz Pusz
8ca2b25349
fix: torque literal fixed + experimental_angle example refactored
2021-04-07 19:07:25 +02:00
Mateusz Pusz
b982921d27
refactor: References are now guarded UNITS_REFERENCES with (ON by default) + examples duplicated to subdirectories
...
Now References can be disabled to meassure a compile time impact. Also the same examples are now provided in two subdirectories to be able to easily compare the pros and cons of every quantity construction technique.
2021-04-06 15:57:28 +02:00
Mateusz Pusz
c3659dbb47
refactor: UNITS_UDLS renamed to UNITS_LITERALS
...
Also now the existence of the preprocessor flag is enough to trigger the feature (`#ifdef` instead of `#if`)
2021-04-06 13:33:27 +02:00
Mateusz Pusz
dfd209ed14
fix: femtotonne enabled
2021-04-02 18:57:17 +02:00
Mateusz Pusz
1a5b4fc85e
refactor: UDLs support switched off by default
2021-04-02 18:56:28 +02:00
Mateusz Pusz
441db47928
fix: MSVC Release build fixed + pragmas usage refactored
2021-03-30 20:00:23 +02:00
Mateusz Pusz
8a26eaf420
fix: VS build fixed
2021-03-30 14:47:05 +02:00
Mateusz Pusz
37cfc53d1d
refactor: IWYU applied to the source files
...
`alternative_namespaces` examples left out as I consider them a subject for removal in the nearest future.
2021-03-30 13:21:05 +02:00
Mateusz Pusz
1197fa1ec4
fix: MSVC shadowing warning disabled for fmt_unit_test.cpp
2021-03-19 23:31:36 +01:00
Mateusz Pusz
fc7b0e44e2
feat: 💥 !data system renamed to isq::iec80000 (quantity names renamed too)
...
Relates to #253
2021-03-19 23:04:52 +01:00
Mateusz Pusz
07cb258eff
Merge branch 'add_symbolrate' of https://github.com/go2sh/units into go2sh-add_symbolrate
2021-03-19 07:35:20 +01:00
Mateusz Pusz
6c4dc95897
Merge branch 'add_si_prefix_bit' of https://github.com/go2sh/units into go2sh-add_si_prefix_bit
2021-03-19 07:24:53 +01:00
Mateusz Pusz
901b09fd52
refactor: quantity::count() renamed to quantity::number()
...
Resolves #259
2021-03-19 06:47:37 +01:00
Mateusz Pusz
221883bb25
build: core library and each system separated to dedicated CMake targets
...
Refers to #249
2021-03-16 23:05:45 +01:00
Mateusz Pusz
bbbb77286c
refactor: physical replaced with isq
...
Refers to #249
2021-03-16 12:03:25 +01:00
Mateusz Pusz
23720d055e
refactor: Refactored the library file tree
...
Resolves #249
2021-03-16 09:32:28 +01:00
Mateusz Pusz
5c94a40906
build: COMP_XXX renamed to UNITS_COMP_XXX
2021-03-15 21:13:21 +01:00
Mateusz Pusz
8f04bd9cfe
build: mp::units CMake target was a bad idea -> mp-units::mp-units is back
2021-02-15 17:06:09 +01:00
Mateusz Pusz
4d965d7f47
fix: 💥 dim_torque now properly divides by an angle (instead of multiply) + default unit name change
...
Resolves #220
2021-02-15 15:01:56 +01:00
Christoph Seitz
c429bb6d3f
Add symbolrate as alias unit for frequency.
2021-01-01 21:52:37 +01:00
Christoph Seitz
d568cfa1b3
Add SI prefix to bit unit.
2021-01-01 17:31:52 +01:00
dkavolis
23dd21465d
rational powers
2020-12-29 17:04:38 +01:00
Mateusz Pusz
cff718301c
refactor: quantity_io added
2020-12-28 15:18:36 +01:00
Mateusz Pusz
008dec79ea
refactor: si.h usage limited
2020-12-28 14:34:27 +01:00
Mateusz Pusz
bf3815a5ee
test: Uniform distribution tests fixed
2020-12-23 22:28:46 +01:00
Mateusz Pusz
a172f34684
build: Minimum CMake version required set for each file based on its contents
2020-12-21 22:56:00 +01:00
Mateusz Pusz
206712f046
build: Library renamed to mp::units
2020-12-17 23:06:37 +01:00
Mateusz Pusz
c5919d2cd8
build: Conan generator changed to provide more transparent dependency handling
2020-12-09 18:49:39 +01:00
Mateusz Pusz
d4d23847d8
refactor: DOWNCAST_MODE renamed to UNITS_DOWNCAST_MODE
2020-09-13 18:45:46 +02:00
Mateusz Pusz
6e510b3a2a
refactor: modules-like behavior for systems removed to improve broken compile-time
...
Reffers to #32
2020-09-13 00:11:02 +02:00
Mateusz Pusz
2a56438f1c
refactor: file tree with systems defninitions refactored to limit ODR issues
...
Relates to #32 as with this commit we created something like modules for derived quantities
2020-09-11 18:11:25 +02:00
rbrugo
1061d2ac56
Fixed indentation
2020-09-10 23:09:12 +02:00
rbrugo
b0428d623a
Added tests for localization
2020-09-10 23:09:12 +02:00
Mateusz Pusz
79558a6d72
refactor: systems defined in terms of SI moved under si namespace
2020-09-10 17:14:33 +02:00
Mateusz Pusz
9cd0cb4105
feat: two argument explicit cast support added
2020-09-10 13:01:38 +02:00
Mateusz Pusz
58daacfd58
fix: unit tests fixed for DOWNCAST_MODE = OFF
2020-09-10 11:33:58 +02:00
Mateusz Pusz
9527b39005
refactor: 💥 q_* UDL renamed to _q_*
...
We had some fun exploring the STD UDLs for potential collisions,
we have learnt our lesson and know how to proceed.
Now is high time to start behaving and obeying C++ rules.
2020-09-09 19:20:35 +02:00