Repository navigation
Tags
Tags
Prevent external construction of checked iterators (#1263) * Prevent external construction of checked iterators Keep iterator state constructors private to span and dyn_array so callers cannot fabricate bounds metadata. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * clang-format --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
replace BYTE_TYPE with a solution based on namespaces (#1201) - A macro with the very generic name `BYTE_TYPE` is likely to collide with existing code, so get rid of the macro. - The new solution is to provide a non-deprecated `byte` in the namespace `gsl::impl`. - Users of GSL should use `gsl::byte`, which is still deprecated when mapped to a `std::std::byte`. - GSL types and functions need to use `gsl::impl::byte` so they do not trigger the deprecation warning. - The `gsl::impl::byte` return type in an exported function is not nice, it might mislead users to use that type in their own declarations. But the `BYTE_TYPE` solution is not better in this respect. Co-authored-by: Werner Henze <w.henze@avm.de>
PreviousNext