mirror of
https://github.com/mpusz/mp-units.git
synced 2025-06-25 01:01:33 +02:00
feat(example): is_vector
specialization no longer needed for si_constants
This commit is contained in:
@ -16,19 +16,11 @@ work in practice.
|
||||
--8<-- "example/si_constants.cpp:28:40"
|
||||
```
|
||||
|
||||
As always, we start with the inclusion of all the needed header files. After that, for
|
||||
the simplicity of this example, we
|
||||
[hack the character of quantities](../framework_basics/character_of_a_quantity.md#hacking-the-character)
|
||||
to be able to express vector quantities with simple scalar types.
|
||||
|
||||
```cpp title="si_constants.cpp" linenums="14"
|
||||
--8<-- "example/si_constants.cpp:42:44"
|
||||
```
|
||||
|
||||
As always, we start with the inclusion of all the needed header files.
|
||||
The main part of the example prints all of the SI-defining constants:
|
||||
|
||||
```cpp title="si_constants.cpp" linenums="17"
|
||||
--8<-- "example/si_constants.cpp:45:"
|
||||
```cpp title="si_constants.cpp" linenums="14"
|
||||
--8<-- "example/si_constants.cpp:42:"
|
||||
```
|
||||
|
||||
While analyzing the output of this program (provided below), we can easily notice that a direct
|
||||
|
Reference in New Issue
Block a user