Unverified Commit fb37e507 authored by Nikita Titov's avatar Nikita Titov Committed by GitHub
Browse files

Remove leftovers after the drop of Solaris support (#5248)

* Update tree.cpp

* Update common.h

* Update common.h
parent 23da5fc5
......@@ -29,11 +29,9 @@
#include <utility>
#include <vector>
#if (!((defined(sun) || defined(__sun)) && (defined(__SVR4) || defined(__svr4__))))
#define FMT_HEADER_ONLY
#include "../../../external_libs/fmt/include/fmt/format.h"
#endif
#include "../../../external_libs/fast_double_parser/include/fast_double_parser.h"
#include "../../../external_libs/fmt/include/fmt/format.h"
#ifdef _MSC_VER
#include <intrin.h>
......@@ -1192,7 +1190,6 @@ inline static std::vector<T> StringToArray(const std::string& str, char delimite
return ret;
}
#if (!((defined(sun) || defined(__sun)) && (defined(__SVR4) || defined(__svr4__))))
/*!
* Safely formats a value onto a buffer according to a format string and null-terminates it.
*
......@@ -1257,7 +1254,6 @@ inline static std::string ArrayToString(const std::vector<T>& arr, size_t n) {
}
return str_buf.str();
}
#endif // (!((defined(sun) || defined(__sun)) && (defined(__SVR4) || defined(__svr4__))))
} // namespace CommonC
......
......@@ -340,11 +340,7 @@ std::string Tree::ToString() const {
std::stringstream str_buf;
Common::C_stringstream(str_buf);
#if ((defined(sun) || defined(__sun)) && (defined(__SVR4) || defined(__svr4__)))
using CommonLegacy::ArrayToString; // Slower & unsafe regarding locale.
#else
using CommonC::ArrayToString;
#endif
str_buf << "num_leaves=" << num_leaves_ << '\n';
str_buf << "num_cat=" << num_cat_ << '\n';
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment