feat: import std; support added

Resolves #595
This commit is contained in:
Mateusz Pusz
2024-07-16 17:36:00 +02:00
parent a4691825ee
commit b870b85c25
93 changed files with 425 additions and 9 deletions

View File

@ -21,7 +21,11 @@
// SOFTWARE.
#include <catch2/catch_test_macros.hpp>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <atomic>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -21,12 +21,16 @@
// SOFTWARE.
#include <catch2/catch_test_macros.hpp>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <array>
#include <cstddef>
#include <cstdint>
#include <initializer_list>
#include <random>
#include <vector>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -24,8 +24,12 @@
#include <catch2/matchers/catch_matchers_exception.hpp>
#include <mp-units/compat_macros.h>
#include <mp-units/ext/format.h>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <sstream>
#include <string_view>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -25,6 +25,9 @@
#include <catch2/matchers/catch_matchers_exception.hpp>
#include <mp-units/compat_macros.h>
#include <mp-units/ext/format.h>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <cstdint>
#include <iomanip>
#include <limits>
@ -32,6 +35,7 @@
#include <sstream>
#include <string>
#include <string_view>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -23,8 +23,12 @@
#include <catch2/catch_test_macros.hpp>
#include <mp-units/compat_macros.h>
#include <mp-units/ext/format.h>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <matrix>
#include <ostream>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -23,7 +23,11 @@
#include "almost_equals.h"
#include <catch2/catch_test_macros.hpp>
#include <catch2/matchers/catch_matchers.hpp>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <limits>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else

View File

@ -25,8 +25,12 @@
#include <catch2/catch_test_macros.hpp>
#include <catch2/matchers/catch_matchers.hpp>
#include <mp-units/ext/format.h>
#ifdef MP_UNITS_IMPORT_STD
import std;
#else
#include <limits>
#include <numbers>
#endif
#ifdef MP_UNITS_MODULES
import mp_units;
#else