Fixed previous commit for Linux/OSX
This commit is contained in:
parent
1130d78c19
commit
5ccd9d9d9a
1 changed files with 3 additions and 1 deletions
|
@ -977,7 +977,9 @@ template<typename T>
|
|||
{
|
||||
// Legacy conversion, which is costly due to having to make a copy of the string before conversion.
|
||||
try {
|
||||
std::string str { str };
|
||||
assert(sv.size() < 1024);
|
||||
assert(sv.data() != nullptr);
|
||||
std::string str { sv };
|
||||
size_t read = 0;
|
||||
if constexpr (std::is_same_v<T, int>)
|
||||
out = std::stoi(str, &read);
|
||||
|
|
Loading…
Reference in a new issue