214. Use the std::span container from C++ 20 to view a contiguous Fortran array with a STL-compatible interface.#
topic: Interoperability with C and C++
Note
This tip is a draft1.
Use the std::span container from C++ 20 to create a view of a contiguous Fortran array with a STL-compatible interface. std::sort will sort the array in-place. Also works for other STL algorithms. From @IvanPribec. #cpp
Use the std::span container from C++ 20 to create a view of a contiguous Fortran array with a STL-compatible interface. std::sort will sort the array in-place. Also works for other STL algorithms.
— FortranTip (@fortrantip) May 12, 2022
From @IvanPribec. #cpppic.twitter.com/WVazkhQ5Et
- 1
From the perspective of FortranTip Browser, “draft” means that it hasn’t been edited for formatting, hasn’t had corresponding Fortran programs added, the text content hasn’t been enhanced, etc. Draft texts are extracted from the corresponding Tweet using the Twitter API.