Skip to content

Commit

Permalink
fix: Typos in Timestamp (#11830)
Browse files Browse the repository at this point in the history
Summary: Pull Request resolved: #11830

Reviewed By: xiaoxmeng

Differential Revision: D67186249

Pulled By: zacw7

fbshipit-source-id: a1e0f45f899677f402d8f09fdccf1857fff4b4d9
  • Loading branch information
zuyu authored and facebook-github-bot committed Dec 13, 2024
1 parent 960c2af commit 67a0c04
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions velox/type/Timestamp.h
Original file line number Diff line number Diff line change
Expand Up @@ -156,11 +156,11 @@ struct Timestamp {

// Keep it in header for getting inlined.
int64_t toMillis() const {
// We use int128_t to make sure the computation does not overflows since
// We use int128_t to make sure the computation does not overflow since
// there are cases such that seconds*1000 does not fit in int64_t,
// but seconds*1000 + nanos does, an example is TimeStamp::minMillis().

// If the final result does not fit in int64_tw we throw.
// If the final result does not fit in int64_t we throw.
__int128_t result =
(__int128_t)seconds_ * 1'000 + (int64_t)(nanos_ / 1'000'000);
if (result < std::numeric_limits<int64_t>::min() ||
Expand Down

0 comments on commit 67a0c04

Please sign in to comment.