Skip to content

Commit 8a786be

Browse files
authored
[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 <[email protected]>
1 parent 6cc363e commit 8a786be

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp

+4
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,8 @@ struct InitializePythonRAII {
183183
// Python 3.13. It has been returning `true` always since Python 3.7.
184184
#if (PY_MAJOR_VERSION == 3 && PY_MINOR_VERSION < 9) || (PY_MAJOR_VERSION < 3)
185185
if (PyEval_ThreadsInitialized()) {
186+
#else
187+
if (true) {
186188
#endif
187189
Log *log = GetLog(LLDBLog::Script);
188190

@@ -199,6 +201,8 @@ struct InitializePythonRAII {
199201

200202
// InitThreads acquires the GIL if it hasn't been called before.
201203
PyEval_InitThreads();
204+
#else
205+
}
202206
#endif
203207
}
204208

0 commit comments

Comments
 (0)