2020-04-22 19:29:27 -03:00
|
|
|
#ifndef Py_PEGENINTERFACE
|
|
|
|
#define Py_PEGENINTERFACE
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2020-04-23 12:36:06 -03:00
|
|
|
#ifndef Py_BUILD_CORE
|
|
|
|
# error "this header requires Py_BUILD_CORE define"
|
|
|
|
#endif
|
|
|
|
|
2020-04-22 19:29:27 -03:00
|
|
|
#include "Python.h"
|
|
|
|
#include "Python-ast.h"
|
|
|
|
|
2020-04-27 14:02:07 -03:00
|
|
|
PyAPI_FUNC(mod_ty) PyPegen_ASTFromFile(const char *filename, int mode, PyCompilerFlags*, PyArena *arena);
|
2020-04-22 19:29:27 -03:00
|
|
|
PyAPI_FUNC(mod_ty) PyPegen_ASTFromString(const char *str, int mode, PyCompilerFlags *flags,
|
|
|
|
PyArena *arena);
|
|
|
|
PyAPI_FUNC(mod_ty) PyPegen_ASTFromStringObject(const char *str, PyObject* filename, int mode,
|
|
|
|
PyCompilerFlags *flags, PyArena *arena);
|
|
|
|
PyAPI_FUNC(mod_ty) PyPegen_ASTFromFileObject(FILE *fp, PyObject *filename_ob,
|
|
|
|
int mode, const char *enc, const char *ps1,
|
2020-04-27 14:02:07 -03:00
|
|
|
const char *ps2, PyCompilerFlags *flags,
|
|
|
|
int *errcode, PyArena *arena);
|
|
|
|
PyAPI_FUNC(PyCodeObject *) PyPegen_CodeObjectFromFile(const char *filename, int mode, PyCompilerFlags *flags);
|
2020-04-22 19:29:27 -03:00
|
|
|
PyAPI_FUNC(PyCodeObject *) PyPegen_CodeObjectFromString(const char *str, int mode,
|
|
|
|
PyCompilerFlags *flags);
|
|
|
|
PyAPI_FUNC(PyCodeObject *) PyPegen_CodeObjectFromFileObject(FILE *, PyObject *filename_ob,
|
2020-04-27 14:02:07 -03:00
|
|
|
int mode,
|
2020-04-22 19:29:27 -03:00
|
|
|
const char *ps1,
|
|
|
|
const char *ps2,
|
2020-04-27 14:02:07 -03:00
|
|
|
PyCompilerFlags *flags,
|
|
|
|
const char *enc,
|
2020-04-22 19:29:27 -03:00
|
|
|
int *errcode);
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
#endif /* !Py_PEGENINTERFACE*/
|