wesm commented on a change in pull request #7088:
URL: https://github.com/apache/arrow/pull/7088#discussion_r419792382
##########
File path: cpp/src/arrow/util/value_parsing.cc
##########
@@ -79,5 +86,46 @@ bool StringToFloatConverter::StringToFloat(const char* s,
size_t length, double*
return true;
}
+// ----------------------------------------------------------------------
+// strptime-like parsing
+
+class StrptimeTimestampParser : public TimestampParser {
+ public:
+ explicit StrptimeTimestampParser(std::string format) :
format_(std::move(format)) {}
+
+ bool operator()(const char* s, size_t length, TimeUnit::type out_unit,
+ value_type* out) const override {
+ arrow_vendored::date::sys_seconds time_point;
+ std::istringstream stream(std::string(s, length));
+ if (stream >> arrow_vendored::date::parse(format_, time_point)) {
Review comment:
This won't work anyway because HowardHinnant/date doesn't completely
work with gcc < 7
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]