mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-26 01:22:04 +00:00
Remove unused field
This commit is contained in:
parent
3e19f4a00f
commit
cf0912ba02
@ -54,7 +54,6 @@ DateLUTImpl::DateLUTImpl(const std::string & time_zone_)
|
|||||||
const cctz::civil_day epoch{1970, 1, 1};
|
const cctz::civil_day epoch{1970, 1, 1};
|
||||||
const cctz::civil_day lut_start{DATE_LUT_MIN_YEAR, 1, 1};
|
const cctz::civil_day lut_start{DATE_LUT_MIN_YEAR, 1, 1};
|
||||||
time_t start_of_day;
|
time_t start_of_day;
|
||||||
time_offset_epoch = cctz::convert(cctz::civil_second(lut_start), cctz_time_zone).time_since_epoch().count();
|
|
||||||
|
|
||||||
// Note: it's validated against all timezones in the system.
|
// Note: it's validated against all timezones in the system.
|
||||||
assert((epoch - lut_start) == daynum_offset_epoch);
|
assert((epoch - lut_start) == daynum_offset_epoch);
|
||||||
|
@ -169,7 +169,6 @@ private:
|
|||||||
/// UTC offset at the beginning of the first supported year.
|
/// UTC offset at the beginning of the first supported year.
|
||||||
time_t offset_at_start_of_lut;
|
time_t offset_at_start_of_lut;
|
||||||
bool offset_is_whole_number_of_hours_everytime;
|
bool offset_is_whole_number_of_hours_everytime;
|
||||||
time_t time_offset_epoch;
|
|
||||||
|
|
||||||
/// Time zone name.
|
/// Time zone name.
|
||||||
std::string time_zone;
|
std::string time_zone;
|
||||||
@ -230,7 +229,6 @@ public:
|
|||||||
// Methods only for unit-testing, it makes very little sense to use it from user code.
|
// Methods only for unit-testing, it makes very little sense to use it from user code.
|
||||||
auto getOffsetAtStartOfEpoch() const { return offset_at_start_of_epoch; }
|
auto getOffsetAtStartOfEpoch() const { return offset_at_start_of_epoch; }
|
||||||
auto getOffsetIsWholNumberOfHoursEveryWhere() const { return offset_is_whole_number_of_hours_everytime; }
|
auto getOffsetIsWholNumberOfHoursEveryWhere() const { return offset_is_whole_number_of_hours_everytime; }
|
||||||
auto getTimeOffsetEpoch() const { return time_offset_epoch; }
|
|
||||||
auto getTimeOffsetAtStartOfLUT() const { return offset_at_start_of_lut; }
|
auto getTimeOffsetAtStartOfLUT() const { return offset_at_start_of_lut; }
|
||||||
|
|
||||||
/// All functions below are thread-safe; arguments are not checked.
|
/// All functions below are thread-safe; arguments are not checked.
|
||||||
|
@ -292,7 +292,6 @@ TEST_P(DateLUTWithTimeZone, VaidateTimeComponentsAroundEpoch)
|
|||||||
<< "\n\ttimestamp: " << i
|
<< "\n\ttimestamp: " << i
|
||||||
<< "\n\t offset at start of epoch : " << lut.getOffsetAtStartOfEpoch()
|
<< "\n\t offset at start of epoch : " << lut.getOffsetAtStartOfEpoch()
|
||||||
<< "\n\t offset_is_whole_number_of_hours_everytime : " << lut.getOffsetIsWholNumberOfHoursEveryWhere()
|
<< "\n\t offset_is_whole_number_of_hours_everytime : " << lut.getOffsetIsWholNumberOfHoursEveryWhere()
|
||||||
<< "\n\t time_offset_epoch : " << lut.getTimeOffsetEpoch()
|
|
||||||
<< "\n\t offset_at_start_of_lut : " << lut.getTimeOffsetAtStartOfLUT());
|
<< "\n\t offset_at_start_of_lut : " << lut.getTimeOffsetAtStartOfLUT());
|
||||||
|
|
||||||
EXPECT_GE(24, lut.toHour(i));
|
EXPECT_GE(24, lut.toHour(i));
|
||||||
|
Loading…
Reference in New Issue
Block a user