From 28f737a15d9ce5d9e8b06ab768ef858c07ae510e Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Tue, 5 Sep 2023 15:20:13 +0300 Subject: Make c++11 value default for xsd --std option Also add support for c++14, c++17, c++20, and c++23 values and drop passing --std option in tests and examples. --- xsd/xsd/cxx/options.cli | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'xsd/xsd/cxx/options.cli') diff --git a/xsd/xsd/cxx/options.cli b/xsd/xsd/cxx/options.cli index 2c50f19..1eb1b61 100644 --- a/xsd/xsd/cxx/options.cli +++ b/xsd/xsd/cxx/options.cli @@ -15,17 +15,19 @@ namespace CXX { // Language. // - cxx_version --std = cxx_version::cxx98 + cxx_version --std = cxx_version::cxx11 { "", "Specify the C++ standard that the generated code should conform to. - Valid values are \cb{c++98} (default) and \cb{c++11}. + Valid values are \cb{c++98}, \cb{c++11} (default), \cb{c++14}, + \cb{c++17}, \cb{c++20}, and \cb{c++23}. The C++ standard affects various aspects of the generated code that are discussed in more detail in various mapping-specific documentation. Overall, when C++11 is selected, the generated code relies on the move semantics and uses \cb{std::unique_ptr} - instead of deprecated \cb{std::auto_ptr}. + instead of deprecated \cb{std::auto_ptr}. Currently, there is no + difference between the C++11 and the later standards modes. When the C++11 mode is selected, you normally don't need to perform any extra steps other than enable C++11 in your C++ -- cgit v1.1