From db040c8231aa4af6f79731cef183cdfe5187e5ce Mon Sep 17 00:00:00 2001 From: "Orend, Dr Jan (ORJ)" <56254096+3dJan@users.noreply.github.com> Date: Fri, 20 Oct 2023 10:47:53 +0200 Subject: [PATCH] Setting c++17 for all compiler --- CMakeLists.txt | 1 + Source/Common/NMR_StringUtils.cpp | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 38e013615..35ff1948a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -34,6 +34,7 @@ option(USE_INCLUDED_SSL "Use included libressl" ON) option(BUILD_FOR_CODECOVERAGE "Build for code coverage analysis" OFF) add_compile_options($<$:/MP>) +set (CMAKE_CXX_STANDARD 17) if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") # using GCC diff --git a/Source/Common/NMR_StringUtils.cpp b/Source/Common/NMR_StringUtils.cpp index 18f6c22c1..32cb5b092 100644 --- a/Source/Common/NMR_StringUtils.cpp +++ b/Source/Common/NMR_StringUtils.cpp @@ -155,8 +155,6 @@ namespace NMR { nfDouble dResult = 0.0; // Convert to double and make a input and range check! - nfChar * pEndPtr; - std::from_chars_result result = std::from_chars(pszValue, pszValue + strlen(pszValue), dResult); // Check if any conversion happened