Skip to content

Commit

Permalink
update after cr
Browse files Browse the repository at this point in the history
  • Loading branch information
NEUpanning committed Oct 10, 2024
1 parent abee861 commit 9b14344
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions velox/functions/lib/DateTimeFormatter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,8 @@ struct Date {
bool centuryFormat = false;

bool isYearOfEra = false; // Year of era cannot be zero or negative.
bool hasYear = false;
// Whether dayOfWeek was explicitly specified.
bool hasDayOfWeek = false;
bool hasYear = false; // Whether year was explicitly specified.
bool hasDayOfWeek = false; // Whether dayOfWeek was explicitly specified.

int32_t hour = 0;
int32_t minute = 0;
Expand Down Expand Up @@ -999,10 +998,10 @@ int32_t parseFromPattern(
}
}
date.dayOfWeek = number;
date.hasDayOfWeek = true;
if (!date.weekOfMonthDateFormat) {
date.weekDateFormat = true;
}
date.hasDayOfWeek = true;
date.dayOfYearFormat = false;
if (!date.hasYear) {
date.hasYear = true;
Expand Down

0 comments on commit 9b14344

Please sign in to comment.