File
Blob: src/workerd/server/v8-platform-impl.c++
| 1 | // Copyright (c) 2017-2022 Cloudflare, Inc. |
| 2 | // Licensed under the Apache 2.0 license found in the LICENSE file or at: |
| 3 | // https://opensource.org/licenses/Apache-2.0 |
| 4 | |
| 5 | #include "v8-platform-impl.h" |
| 6 | |
| 7 | #include <kj/time.h> |
| 8 | |
| 9 | namespace workerd::server { |
| 10 | |
| 11 | double WorkerdPlatform::CurrentClockTimeMillis() noexcept { |
| 12 | return (kj::systemPreciseCalendarClock().now() - kj::UNIX_EPOCH) / kj::MILLISECONDS; |
| 13 | } |
| 14 | |
| 15 | } // namespace workerd::server |