Skip to content

Commit

Permalink
[fnStringToDouble] Adding std::chars_format::general, not all compile…
Browse files Browse the repository at this point in the history
…r seem to support the overload with 3 arguments
  • Loading branch information
3dJan committed Oct 20, 2023
1 parent db040c8 commit 78d4743
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/Common/NMR_StringUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ namespace NMR {
nfDouble dResult = 0.0;

// Convert to double and make a input and range check!
std::from_chars_result result = std::from_chars(pszValue, pszValue + strlen(pszValue), dResult);
std::from_chars_result result = std::from_chars(pszValue, pszValue + strlen(pszValue), dResult, std::chars_format::general);

// Check if any conversion happened
if (result.ec == std::errc::invalid_argument || result.ec == std::errc::result_out_of_range)
Expand Down

0 comments on commit 78d4743

Please sign in to comment.