File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed
Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change 1+ * Support for "import std;" is enabled by defining the macro
2+ STRONG_TYPE_IMPORT_STD_LIBRARY. This has currently only been
3+ tested on MSVC with C++20 and C++23. Other compilers may or
4+ may not work at this point. You can also run the unit-tests
5+ with "import std;" by adding the CMake option
6+ -DSTRONG_TYPE_IMPORT_STD_LIBRARY=yes
7+
8+ Huge thangs to David Hunter for contributing this addition.
9+
110 * Make strong::range work with range types that only has
211 const_iterator types (e.g. std::set). Thanks David Feltell for
312 reporting the problem.
Original file line number Diff line number Diff line change @@ -68,6 +68,9 @@ A strong type can be used as an NTTP ([Non Type Template
6868Parameter](https://en.cppreference.com/w/cpp/language/template_parameters)), if
6969the underlying type can be, for compilers and standards that support it.
7070
71+ *strong_type* uses the std library module, with `import std;` if you
72+ define the macro `STRONG_TYPE_IMPORT_STD_LIBRARY=1`.
73+
7174# <A name="modifiers"/> Modifiers:
7275
7376* <A name="affine_point"/>`strong::affine_point<D>` allows instances to be
@@ -681,10 +684,14 @@ cmake <strong_type_dir> -DSTRONG_TYPE_UNIT_TEST=yes
681684cmake --build .
682685```
683686
684- This will produce the test programs ` self_test ` , and conditionally also
687+ You can also add the option ` -DSTRONG_TYPE_IMPORT_STD_LIBRARY=yes ` if your
688+ development environment supports C++20 "` import std; ` "
689+
690+ The build will produce the test programs ` self_test ` , and conditionally also
685691` test_fmt8 ` ,` test_fmt9 ` , ` test_fmt10 ` and ` test_fmt11 ` , depending on which version(s) of
686692[ ` {fmt} ` ] ( https://fmt.dev/latest/index.html )
687693
694+
688695N.B. Microsoft Visual Studio MSVC compiler < 19.22 does not handle ` constexpr `
689696correctly. Those found to cause trouble are disabled for those versions.
690697
You can’t perform that action at this time.
0 commit comments