[3.12] gh-127902: Make sure extern "C" is closed when using Py_LIMITED_API (#127904)

Fixes #127902.
This commit is contained in:
Dmitry Shachnev 2024-12-13 14:18:28 +03:00 committed by GitHub
parent 2d317332c0
commit b184f4859a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,10 +1,10 @@
#ifndef Py_TRACEMALLOC_H
#define Py_TRACEMALLOC_H
#ifndef Py_LIMITED_API
#ifdef __cplusplus
extern "C" {
#endif
#ifndef Py_LIMITED_API
/* Track an allocated memory block in the tracemalloc module.
Return 0 on success, return -1 on error (failed to allocate memory to store
the trace).