diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2021-02-18 14:41:57 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2021-02-18 14:41:57 +0800 |
commit | f9c45800068f2d75aa988af03a9e3017bc5dd72f (patch) | |
tree | 20957083f42e29736ff2ca8dc573f16bb3a1afe4 /script/brave | |
parent | da9febfb5ea5972f3062063e987af18497bf43fe (diff) | |
download | lua-language-server-f9c45800068f2d75aa988af03a9e3017bc5dd72f.zip |
fix log time of sub threads
Diffstat (limited to 'script/brave')
-rw-r--r-- | script/brave/log.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/script/brave/log.lua b/script/brave/log.lua index 18ea7853..d7c92b26 100644 --- a/script/brave/log.lua +++ b/script/brave/log.lua @@ -1,11 +1,12 @@ local brave = require 'brave' +local time = require 'bee.time' local tablePack = table.pack local tostring = tostring local tableConcat = table.concat local debugTraceBack = debug.traceback local debugGetInfo = debug.getinfo -local osClock = os.clock +local monotonic = time.monotonic _ENV = nil @@ -24,7 +25,7 @@ local function pushLog(level, ...) msg = str, src = info.source, line = info.currentline, - clock = osClock(), + clock = monotonic(), }) return str end |