<HTML><BODY><div>Hi!</div><div>Thanks for the patch!</div><div>LGTM</div><div data-signature-widget="container"><div data-signature-widget="content"><div>--<br>Best regards,</div><div>Maxim Kokryashkin</div></div></div><div> </div><div> </div><blockquote style="border-left:1px solid #0857A6; margin:10px; padding:0 0 0 10px;"><div> <blockquote style="border-left:1px solid #0857A6; margin:10px; padding:0 0 0 10px;"><div id=""><div class="js-helper js-readmsg-msg"><div><div id="style_16914165340350088821_BODY">This <assert> misuse was introduced in the initial implementation of GDB<br>extension within the commit 58790750b9c4bd4c21d883f109ab552a2e202a15<br>("gdb: introduce luajit-gdb extension") and also propagated to the<br>initial implementation of LLDB extension by copy-pasting in scope of the<br>commit 62fc84a8f89b8e5650162ba1c7696b0f84cf5c25 ("lldb: introduce<br>luajit-lldb"). However, <assert> is not a function, but statement, so<br>parenthesis around the condition are considered as a tuple constructor.<br>This patch simply removes the excess parenthesis to finally follow<br>Python semantics of the <assert> statement.<br><br>Signed-off-by: Igor Munkin <<a href="/compose?To=imun@tarantool.org">imun@tarantool.org</a>><br>---<br><br>**NB**: This patch will be placed before "[PATCH luajit 01/15] test: fix<br>E122 errors by pycodestyle" on the branch.<br><br>CI: <a href="https://github.com/tarantool/luajit/actions/runs/5785962723/job/15679677849" target="_blank">https://github.com/tarantool/luajit/actions/runs/5785962723/job/15679677849</a><br><br> src/luajit-gdb.py | 2 +-<br> src/luajit_lldb.py | 2 +-<br> 2 files changed, 2 insertions(+), 2 deletions(-)<br><br>diff --git a/src/luajit-gdb.py b/src/luajit-gdb.py<br>index 9075e99f..b7902d53 100644<br>--- a/src/luajit-gdb.py<br>+++ b/src/luajit-gdb.py<br>@@ -327,7 +327,7 @@ def itypemap(o):<br> <br> <br> def funcproto(func):<br>- assert(func['ffid'] == 0)<br>+ assert func['ffid'] == 0<br> <br> return cast('GCproto *',<br> mref('char *', func['pc']) - gdb.lookup_type('GCproto').sizeof)<br>diff --git a/src/luajit_lldb.py b/src/luajit_lldb.py<br>index 85c0dcb9..94f54a59 100644<br>--- a/src/luajit_lldb.py<br>+++ b/src/luajit_lldb.py<br>@@ -516,7 +516,7 @@ def strx64(val):<br> <br> <br> def funcproto(func):<br>- assert(func.ffid == 0)<br>+ assert func.ffid == 0<br> proto_size = sizeof('GCproto')<br> value = cast('uintptr_t', vtou64(mref('char *', func.pc)) - proto_size)<br> return cast(GCprotoPtr, value)<br>--<br>2.30.2</div></div></div></div></blockquote><div> </div></div></blockquote></BODY></HTML>