[ ] Tests for the changes have been added (for bug fixes / features)
[ ] Documentation has been added / updated (for bug fixes / features)
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
This PR introduces NovelRT::Utilities::Misc::Span as alias to gsl::span and std::span according to https://github.com/novelrt/NovelRT/issues/532
What is the current behavior? (You can also link to an open issue here)
Currently across the NovelRT engine gsl::span is used directly
What is the new behavior (if this is a feature change)?
NovelRT will continue to use gsl::span by default, but through an aliased. Through defining NOVELRT_USE_STD_SPAN it will attempt to use C++ 20's std::span instead.
Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)
This PR does not introduce any breaking changes, as NovelRT::Utilities::Misc::Span will still use gsl::span by default. In order to make use of std::span, developers will first have to opt-in.
Other information:
This PR currently only makes changes for C++, it might be possible to create an option in CMake to have it be easier to use.
Please check if the PR fulfills these requirements
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...) This PR introduces
NovelRT::Utilities::Misc::Span
as alias togsl::span
andstd::span
according to https://github.com/novelrt/NovelRT/issues/532Is there an open issue that this resolves? If so, please link it here. https://github.com/novelrt/NovelRT/issues/532
What is the current behavior? (You can also link to an open issue here) Currently across the NovelRT engine
gsl::span
is used directlyWhat is the new behavior (if this is a feature change)? NovelRT will continue to use
gsl::span
by default, but through an aliased. Through definingNOVELRT_USE_STD_SPAN
it will attempt to use C++ 20'sstd::span
instead.Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?) This PR does not introduce any breaking changes, as
NovelRT::Utilities::Misc::Span
will still usegsl::span
by default. In order to make use ofstd::span
, developers will first have to opt-in.Other information: This PR currently only makes changes for C++, it might be possible to create an option in CMake to have it be easier to use.