summaryrefslogtreecommitdiffstats
path: root/Tests/CMakeLib/testOptional.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Tests: Fix reliance on undefined behavior of cm::optionalKyle Edwards2019-11-131-36/+48
| | | | | | | | | | | The test for cm::optional assumed that *opt would return a reference to a non-constructed object if opt.has_value() is false. However, on certain systems that build CMake with flags to harden the build, this condition aborts rather than returning the invalid reference. Fix this by getting the reference only when the cm::optional is known to actually have a value. Fixes: #19964
* Revise include order using clang-format-6.0Kitware Robot2019-10-011-3/+3
| | | | | Run the `clang-format.bash` script to update our C and C++ code to a new include order `.clang-format`. Use `clang-format` version 6.0.
* cmstd: Modernize CMake system headersMarc Chevrier2019-09-201-3/+2
| | | | | | | | | | | | | | Provide a standardized way to handle the C++ "standard" headers customized to be used with current CMake C++ standard constraints. Offer under directory `cm` headers which can be used as direct replacements of the standard ones. For example: #include <cm/string_view> can be used safely for CMake development in place of the `<string_view>` standard header. Fixes: #19491
* Source: Add cm::optionalKyle Edwards2019-08-231-0/+690