From patchwork Wed Jan 8 19:49:51 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: D7779: py3: replace `time.clock()` with `time.perf_counter()` From: phabricator X-Patchwork-Id: 44196 Message-Id: <1351bac51a7a339c2cf11ee2aec96be8@localhost.localdomain> To: Phabricator Cc: mercurial-devel@mercurial-scm.org Date: Wed, 8 Jan 2020 19:49:51 +0000 Closed by commit rHG6b90f5c89cb4: py3: replace `time.clock()` with `time.perf_counter()` (authored by mharbison72). This revision was automatically updated to reflect the committed changes. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D7779?vs=19027&id=19091 CHANGES SINCE LAST ACTION https://phab.mercurial-scm.org/D7779/new/ REVISION DETAIL https://phab.mercurial-scm.org/D7779 AFFECTED FILES mercurial/dispatch.py CHANGE DETAILS To: mharbison72, #hg-reviewers, pulkit Cc: mercurial-devel diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py --- a/mercurial/dispatch.py +++ b/mercurial/dispatch.py @@ -15,7 +15,6 @@ import re import signal import sys -import time import traceback @@ -1040,8 +1039,8 @@ def get_times(): t = os.times() if t[4] == 0.0: - # Windows leaves this as zero, so use time.clock() - t = (t[0], t[1], t[2], t[3], time.clock()) + # Windows leaves this as zero, so use time.perf_counter() + t = (t[0], t[1], t[2], t[3], util.timer()) return t s = get_times()