aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
diff options
context:
space:
mode:
authorMed Ismail Bennani <ismail@bennani.ma>2023-10-30 16:29:46 -0700
committerGitHub <noreply@github.com>2023-10-30 16:29:46 -0700
commit8a786be384fb1279413bd123ce2dfeee9c008bc4 (patch)
treea48f4f6d17aa1c4591c6273fbcfb46f555b80957 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
parent6cc363ed7c9b56a2f3d26d0a88d72b32c1ce9c34 (diff)
downloadllvm-8a786be384fb1279413bd123ce2dfeee9c008bc4.zip
llvm-8a786be384fb1279413bd123ce2dfeee9c008bc4.tar.gz
llvm-8a786be384fb1279413bd123ce2dfeee9c008bc4.tar.bz2
[lldb] Fix misleading indentiation warning in ScriptInterpreterPython (NFC) (#70732)
This should silence the "misleading indentiation" warnings introduced by b2929be, by adding an no-op if-statement, if the surrounding if-statement have been compiled out. Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp')
-rw-r--r--lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
index 968cc8ca..953f8b3 100644
--- a/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
+++ b/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
@@ -183,6 +183,8 @@ private:
// Python 3.13. It has been returning `true` always since Python 3.7.
#if (PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION < 9) || (PY_MAJOR_VERSION < 3)
if (PyEval_ThreadsInitialized()) {
+#else
+ if (true) {
#endif
Log *log = GetLog(LLDBLog::Script);
@@ -199,6 +201,8 @@ private:
// InitThreads acquires the GIL if it hasn't been called before.
PyEval_InitThreads();
+#else
+ }
#endif
}