From 52ce2b21f78c2dba443a6d934cbd8f1d667454d3 Mon Sep 17 00:00:00 2001 From: Mateusz Pusz Date: Fri, 23 Jun 2023 15:03:04 +0200 Subject: [PATCH] refactor: `iostream.h` renamed to `ostream.h` --- README.md | 4 ++-- docs/getting_started/code_example.md | 4 ++-- .../framework_basics/simple_and_typed_quantities.md | 8 ++++---- example/avg_speed.cpp | 2 +- example/capacitor_time_curve.cpp | 2 +- example/clcpp_response.cpp | 2 +- example/currency.cpp | 2 +- example/hello_units.cpp | 2 +- example/measurement.cpp | 2 +- example/strong_angular_quantities.cpp | 2 +- example/total_energy.cpp | 2 +- example/unmanned_aerial_vehicle.cpp | 2 +- src/core-io/CMakeLists.txt | 2 +- src/core-io/include/mp-units/{iostream.h => ostream.h} | 0 test/unit_test/runtime/distribution_test.cpp | 2 +- test/unit_test/runtime/fmt_test.cpp | 2 +- test/unit_test/runtime/linear_algebra_test.cpp | 2 +- test/unit_test/runtime/math_test.cpp | 2 +- test_package/test_package.cpp | 2 +- 19 files changed, 23 insertions(+), 23 deletions(-) rename src/core-io/include/mp-units/{iostream.h => ostream.h} (100%) diff --git a/README.md b/README.md index 4a6c0bda..9079a47d 100644 --- a/README.md +++ b/README.md @@ -79,7 +79,7 @@ accuracy. Please see the below example for a quick preview of basic library feat ```cpp #include -#include +#include #include #include #include @@ -116,4 +116,4 @@ int main() } ``` -_Try it on the [Compiler Explorer](https://godbolt.org/z/T8bovrqTP)._ +_Try it on the [Compiler Explorer](https://godbolt.org/z/3q646qrb3)._ diff --git a/docs/getting_started/code_example.md b/docs/getting_started/code_example.md index 2d3f22da..9ea0d7f5 100644 --- a/docs/getting_started/code_example.md +++ b/docs/getting_started/code_example.md @@ -39,7 +39,7 @@ performed without sacrificing accuracy. Please see the below example for a quick ```cpp #include -#include +#include #include #include #include @@ -76,7 +76,7 @@ int main() } ``` -!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/T8bovrqTP)" +!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/3q646qrb3)" !!! note diff --git a/docs/users_guide/framework_basics/simple_and_typed_quantities.md b/docs/users_guide/framework_basics/simple_and_typed_quantities.md index bcd8cfbd..c6d7c5b3 100644 --- a/docs/users_guide/framework_basics/simple_and_typed_quantities.md +++ b/docs/users_guide/framework_basics/simple_and_typed_quantities.md @@ -50,7 +50,7 @@ have shorter type identifiers, resulting in easier-to-understand error messages Here is a simple example showing how to deal with such quantities: ```cpp -#include +#include #include #include @@ -82,7 +82,7 @@ The code above prints: A car driving 110 km in 2 h has an average speed of 15.2778 m/s (55 km/h) ``` -!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/e5x1cnEqP)" +!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/W6Ej7aqxj)" ## Easy to understand compilation error messages @@ -124,7 +124,7 @@ accident. The previous example can be re-typed using typed quantities in the following way: ```cpp -#include +#include #include #include #include @@ -154,7 +154,7 @@ int main() A car driving 110 km in 2 h has an average speed of 15.2778 m/s (55 km/h) ``` -!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/je6jabh3o)" +!!! example "[Try it on Compiler Explorer](https://godbolt.org/z/98YP8j9b4)" In case we will accidentally make the same calculation error as before, this time, we will get a bit longer error message also containing information about the quantity type: diff --git a/example/avg_speed.cpp b/example/avg_speed.cpp index 1dd64dda..d4c76027 100644 --- a/example/avg_speed.cpp +++ b/example/avg_speed.cpp @@ -20,7 +20,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include +#include #include #include #include diff --git a/example/capacitor_time_curve.cpp b/example/capacitor_time_curve.cpp index 88021616..edee1f1a 100644 --- a/example/capacitor_time_curve.cpp +++ b/example/capacitor_time_curve.cpp @@ -20,8 +20,8 @@ physical_quantities */ -#include #include // IWYU pragma: keep +#include #include #include #include diff --git a/example/clcpp_response.cpp b/example/clcpp_response.cpp index 668a7fa4..47ef636c 100644 --- a/example/clcpp_response.cpp +++ b/example/clcpp_response.cpp @@ -16,7 +16,7 @@ */ #include -#include +#include #include #include #include diff --git a/example/currency.cpp b/example/currency.cpp index 51d6e386..08debb05 100644 --- a/example/currency.cpp +++ b/example/currency.cpp @@ -20,7 +20,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include +#include #include #include #include diff --git a/example/hello_units.cpp b/example/hello_units.cpp index 375769cd..0a5a2e52 100644 --- a/example/hello_units.cpp +++ b/example/hello_units.cpp @@ -26,7 +26,7 @@ // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! #include -#include +#include #include #include #include diff --git a/example/measurement.cpp b/example/measurement.cpp index 1fe61080..bfa86b8d 100644 --- a/example/measurement.cpp +++ b/example/measurement.cpp @@ -20,7 +20,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include +#include #include #include #include diff --git a/example/strong_angular_quantities.cpp b/example/strong_angular_quantities.cpp index 04d41b5e..375a980d 100644 --- a/example/strong_angular_quantities.cpp +++ b/example/strong_angular_quantities.cpp @@ -20,8 +20,8 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include #include +#include #include #include #include diff --git a/example/total_energy.cpp b/example/total_energy.cpp index 321b487f..4b68a750 100644 --- a/example/total_energy.cpp +++ b/example/total_energy.cpp @@ -20,8 +20,8 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include #include +#include #include #include #include diff --git a/example/unmanned_aerial_vehicle.cpp b/example/unmanned_aerial_vehicle.cpp index 43cef183..435cc8f7 100644 --- a/example/unmanned_aerial_vehicle.cpp +++ b/example/unmanned_aerial_vehicle.cpp @@ -21,7 +21,7 @@ // SOFTWARE. #include "geographic.h" -#include +#include #include #include #include diff --git a/src/core-io/CMakeLists.txt b/src/core-io/CMakeLists.txt index 5d79bd07..d4ae7a20 100644 --- a/src/core-io/CMakeLists.txt +++ b/src/core-io/CMakeLists.txt @@ -22,4 +22,4 @@ cmake_minimum_required(VERSION 3.19) -add_units_module(core-io DEPENDENCIES mp-units::core HEADERS include/mp-units/iostream.h) +add_units_module(core-io DEPENDENCIES mp-units::core HEADERS include/mp-units/ostream.h) diff --git a/src/core-io/include/mp-units/iostream.h b/src/core-io/include/mp-units/ostream.h similarity index 100% rename from src/core-io/include/mp-units/iostream.h rename to src/core-io/include/mp-units/ostream.h diff --git a/test/unit_test/runtime/distribution_test.cpp b/test/unit_test/runtime/distribution_test.cpp index d2b31327..98062246 100644 --- a/test/unit_test/runtime/distribution_test.cpp +++ b/test/unit_test/runtime/distribution_test.cpp @@ -21,7 +21,7 @@ // SOFTWARE. #include -#include +#include #include #include #include diff --git a/test/unit_test/runtime/fmt_test.cpp b/test/unit_test/runtime/fmt_test.cpp index 0b5a32fe..73c9a89e 100644 --- a/test/unit_test/runtime/fmt_test.cpp +++ b/test/unit_test/runtime/fmt_test.cpp @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include diff --git a/test/unit_test/runtime/linear_algebra_test.cpp b/test/unit_test/runtime/linear_algebra_test.cpp index 40b84efa..bef57ee7 100644 --- a/test/unit_test/runtime/linear_algebra_test.cpp +++ b/test/unit_test/runtime/linear_algebra_test.cpp @@ -23,8 +23,8 @@ #include #include #include -#include #include +#include #include #include #include diff --git a/test/unit_test/runtime/math_test.cpp b/test/unit_test/runtime/math_test.cpp index a1e93f7d..12d2c209 100644 --- a/test/unit_test/runtime/math_test.cpp +++ b/test/unit_test/runtime/math_test.cpp @@ -22,8 +22,8 @@ #include "almost_equals.h" #include -#include #include +#include #include #include #include diff --git a/test_package/test_package.cpp b/test_package/test_package.cpp index 5c39d71b..729c0083 100644 --- a/test_package/test_package.cpp +++ b/test_package/test_package.cpp @@ -20,7 +20,7 @@ // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. -#include +#include #include #include #include