19357b5d0Sserge-sans-paille //===-- PythonReadline.h ----------------------------------------*- C++ -*-===//
29357b5d0Sserge-sans-paille //
39357b5d0Sserge-sans-paille // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
49357b5d0Sserge-sans-paille // See https://llvm.org/LICENSE.txt for license information.
59357b5d0Sserge-sans-paille // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
69357b5d0Sserge-sans-paille //
79357b5d0Sserge-sans-paille //===----------------------------------------------------------------------===//
89357b5d0Sserge-sans-paille 
99357b5d0Sserge-sans-paille #ifndef LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_PYTHONREADLINE_H
109357b5d0Sserge-sans-paille #define LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_PYTHONREADLINE_H
119357b5d0Sserge-sans-paille 
12*df3ae1ebSMichał Górny #if !defined(LLDB_DISABLE_LIBEDIT) && defined(__linux__)
139357b5d0Sserge-sans-paille // NOTE: Since Python may define some pre-processor definitions which affect the
149357b5d0Sserge-sans-paille // standard headers on some systems, you must include Python.h before any
159357b5d0Sserge-sans-paille // standard headers are included.
169357b5d0Sserge-sans-paille #include "Python.h"
179357b5d0Sserge-sans-paille 
189357b5d0Sserge-sans-paille // no need to hack into Python's readline module if libedit isn't used.
199357b5d0Sserge-sans-paille //
209357b5d0Sserge-sans-paille #define LLDB_USE_LIBEDIT_READLINE_COMPAT_MODULE 1
219357b5d0Sserge-sans-paille 
229357b5d0Sserge-sans-paille extern "C" PyMODINIT_FUNC initlldb_readline(void);
239357b5d0Sserge-sans-paille 
249357b5d0Sserge-sans-paille #endif
259357b5d0Sserge-sans-paille 
269357b5d0Sserge-sans-paille #endif // LLDB_PLUGINS_SCRIPTINTERPRETER_PYTHON_PYTHONREADLINE_H
27