improve a name

This commit is contained in:
Kartik K. Agaram 2023-11-10 10:21:52 -08:00
parent f86ebf6247
commit d90dff3286
1 changed files with 2 additions and 2 deletions

View File

@ -44,7 +44,7 @@ end
function handle_error(err)
local callstack = debug.traceback('', --[[stack frame]]2)
Error_message = 'Error: ' .. tostring(err)..'\n'..clean_up_callstack(callstack)
Error_message = 'Error: ' .. tostring(err)..'\n'..cleaned_up_callstack(callstack)
print(Error_message)
if Current_app == 'run' then
Settings.current_app = 'source'
@ -61,7 +61,7 @@ end
-- rather than offload that to load().
-- Functions compiled in this manner have ugly filenames of the form [string "filename"]
-- This function cleans out this cruft from error callstacks.
function clean_up_callstack(callstack)
function cleaned_up_callstack(callstack)
local frames = {}
for frame in string.gmatch(callstack, '[^\n]+\n*') do
local line = frame:gsub('^%s*(.-)\n?$', '%1')