mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-01-04 02:29:49 -06:00
Code review change
This commit is contained in:
@@ -262,12 +262,9 @@ namespace {
|
||||
size_t nDashes = std::count_if(
|
||||
epoch.begin(),
|
||||
epoch.end(),
|
||||
[]( char c ) {return c =='-';}
|
||||
[](char c) { return c == '-'; }
|
||||
);
|
||||
std::string formatString = "{:4}{:2}{:2}{}";
|
||||
if (nDashes == 2) {
|
||||
formatString = "{:4}-{:2}-{:2}{}";
|
||||
}
|
||||
std::string formatString = (nDashes == 2) ? "{:4}-{:2}-{:2}{}" : "{:4}{:2}{:2}{}";
|
||||
auto [res, year, monthNum, dayOfMonthNum, fractionOfDay] =
|
||||
scn::scan_tuple<int, int, int, double>(e, formatString);
|
||||
if (!res) {
|
||||
|
||||
Reference in New Issue
Block a user