From: Igor Munkin via Tarantool-patches <tarantool-patches@dev.tarantool.org> To: Timur Safin <tsafin@tarantool.org> Cc: alexander.turenko@tarantool.org, tarantool-patches@dev.tarantool.org Subject: Re: [Tarantool-patches] [PATCH v2 1/3] test: corrected reported error lines Date: Wed, 21 Jul 2021 10:24:57 +0300 [thread overview] Message-ID: <20210721072457.GI11494@tarantool.org> (raw) In-Reply-To: <015801d76d7c$15754c20$405fe460$@tarantool.org> Timur, On 30.06.21, Timur Safin wrote: > : From: Igor Munkin <imun@tarantool.org> > : Subject: Re: [Tarantool-patches] [PATCH v2 1/3] test: corrected reported > : error lines > : > : Timur, > : > > : > : > : > : Minor: Strictly saying :123 part is also broken. > : > > : > O_o, why? Could you please clarify? We report it as line number in the > : > source file, in this case tkt-9a8b09f8e6.test.lua:123 was exactly the > : > caller location? > : > : Do you need the location of definition (:123) or location where the > : function execution is stopped at the moment (:142)? If I got your point, > : you prefer the latter, right? > > FWIW, currentline is pointing _exactly_ to the line number in the file > Which was calling this error, not to the start of function definition. Yes, this is written in Lua Reference Manual[1]. > At least in our cases, when we not introduce any extra do scopes. What is wrong with extra do scopes? > > [Now I start to worry with the question when .linedefined is not 0 > and whether we would need to sum .currentline and .linedefined to > get actual source line in the file?] > > : > if currentline may be missing in the traceback object for any reason. > : > : It may not, considering the flags used for obtaining debug info. > : > : > If it's impossible for the set of requested flags, then I'll get rid > : > of linedefined here. > : > : Yes, <currentline> field is provided by 'l' flag[1]. Please, get rid of > : <linedefined> and the default 0 and drop a few sentences regarding this > : change in commit message. > > Please see my worries about .linedefined above. Currently it's in main scope, > when it will be not main scope, do any extra do create separate scope? Lexical blocks are described here[2]. > Could .currentline be .linedefined related or it's guaranteed to be > Counted from start of file? I see nothing about such odd behaviour in Reference Manual[1], but you can check manually whether LuaJIT works fine in this case. > > : > : [1]: https://www.lua.org/manual/5.1/manual.html#lua_getinfo > : > : -- > : Best regards, > : IM > [1]: https://www.lua.org/manual/5.1/manual.html#3.8 [2]: https://www.lua.org/manual/5.1/manual.html#2.4.2 -- Best regards, IM
next prev parent reply other threads:[~2021-07-21 7:48 UTC|newest] Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-06-11 7:48 [Tarantool-patches] [PATCH v2 0/3] sql: modify explicit and implicit conversion tables Timur Safin via Tarantool-patches 2021-06-11 7:48 ` [Tarantool-patches] [PATCH v2 1/3] test: corrected reported error lines Timur Safin via Tarantool-patches 2021-06-20 18:57 ` Igor Munkin via Tarantool-patches 2021-06-23 21:01 ` Alexander Turenko via Tarantool-patches 2021-06-27 23:16 ` Timur Safin via Tarantool-patches 2021-06-29 16:21 ` Igor Munkin via Tarantool-patches 2021-06-30 6:49 ` Timur Safin via Tarantool-patches 2021-07-21 7:24 ` Igor Munkin via Tarantool-patches [this message] 2021-06-11 7:48 ` [Tarantool-patches] [PATCH v2 2/3] sql: updated explicit conversion table Timur Safin via Tarantool-patches 2021-06-20 18:52 ` Mergen Imeev via Tarantool-patches 2021-06-25 21:26 ` Timur Safin via Tarantool-patches 2021-06-25 21:26 ` [Tarantool-patches] Отзыв: " Timur Safin via Tarantool-patches 2021-06-27 23:46 ` [Tarantool-patches] " Timur Safin via Tarantool-patches 2021-06-11 7:48 ` [Tarantool-patches] [PATCH v2 3/3] sql: updated implicit " Timur Safin via Tarantool-patches 2021-06-20 18:52 ` Mergen Imeev via Tarantool-patches 2021-06-28 0:06 ` Timur Safin via Tarantool-patches 2021-06-20 18:52 ` [Tarantool-patches] [PATCH v2 0/3] sql: modify explicit and implicit conversion tables Mergen Imeev via Tarantool-patches 2021-06-27 23:29 ` Timur Safin via Tarantool-patches
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20210721072457.GI11494@tarantool.org \ --to=tarantool-patches@dev.tarantool.org \ --cc=alexander.turenko@tarantool.org \ --cc=imun@tarantool.org \ --cc=tsafin@tarantool.org \ --subject='Re: [Tarantool-patches] [PATCH v2 1/3] test: corrected reported error lines' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox