From 72cc22e03bac4818cbff9eb826816c2f00b5863d Mon Sep 17 00:00:00 2001 From: Francois Fleuret Date: Mon, 19 Dec 2016 17:19:39 +0100 Subject: [PATCH] OCD cosmetics. --- profiler.lua | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/profiler.lua b/profiler.lua index 231a7c9..d61e5db 100644 --- a/profiler.lua +++ b/profiler.lua @@ -55,7 +55,7 @@ function profiler.decorate(model, functionsToDecorate) .. tostring(model)) end - local toDecorate = model + local toDecorate = getmetatable(model) while not rawget(toDecorate, name) do toDecorate = getmetatable(toDecorate) @@ -123,14 +123,13 @@ function profiler.print(model, nbSamples, totalTime, indent) hint = ' ' else if profiler.color then - hint = ' ' + hint = ' ' .. profiler.colors('red') else - hint = '*' + hint = '* ' end - hint = hint .. profiler.colors('red') end - print(profiler.timingString(indent .. hint .. ' ' .. model.__typename, + print(profiler.timingString(indent .. hint .. model.__typename, localTotal, nbSamples, totalTime)) for l, t in pairs(model.accTime) do -- 2.20.1