forked from python/cpython
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into karatsuba-pylong
- Loading branch information
Showing
64 changed files
with
2,347 additions
and
739 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#ifndef Py_AUDIT_H | ||
#define Py_AUDIT_H | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
|
||
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030d0000 | ||
PyAPI_FUNC(int) PySys_Audit( | ||
const char *event, | ||
const char *argFormat, | ||
...); | ||
|
||
PyAPI_FUNC(int) PySys_AuditTuple( | ||
const char *event, | ||
PyObject *args); | ||
#endif | ||
|
||
|
||
#ifndef Py_LIMITED_API | ||
# define Py_CPYTHON_AUDIT_H | ||
# include "cpython/audit.h" | ||
# undef Py_CPYTHON_AUDIT_H | ||
#endif | ||
|
||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
#endif /* !Py_AUDIT_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#ifndef Py_CPYTHON_AUDIT_H | ||
# error "this header file must not be included directly" | ||
#endif | ||
|
||
|
||
typedef int(*Py_AuditHookFunction)(const char *, PyObject *, void *); | ||
|
||
PyAPI_FUNC(int) PySys_AddAuditHook(Py_AuditHookFunction, void*); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#ifndef Py_INTERNAL_AUDIT_H | ||
#define Py_INTERNAL_AUDIT_H | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
#ifndef Py_BUILD_CORE | ||
# error "this header requires Py_BUILD_CORE define" | ||
#endif | ||
|
||
|
||
/* Runtime audit hook state */ | ||
|
||
typedef struct _Py_AuditHookEntry { | ||
struct _Py_AuditHookEntry *next; | ||
Py_AuditHookFunction hookCFunction; | ||
void *userData; | ||
} _Py_AuditHookEntry; | ||
|
||
|
||
extern int _PySys_Audit( | ||
PyThreadState *tstate, | ||
const char *event, | ||
const char *argFormat, | ||
...); | ||
|
||
// _PySys_ClearAuditHooks() must not be exported: use extern rather than | ||
// PyAPI_FUNC(). We want minimal exposure of this function. | ||
extern void _PySys_ClearAuditHooks(PyThreadState *tstate); | ||
|
||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
#endif /* !Py_INTERNAL_AUDIT_H */ |
Oops, something went wrong.