mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-07 08:57:36 +08:00
We have a longstanding project convention that all .h files should be includable with no prerequisites other than postgres.h. This is tested/relied-on by cpluspluscheck. However, cpluspluscheck has not historically been applied to most headers outside the src/include tree, with the predictable consequence that some of them don't work. Fix that, usually by adding missing #include dependencies. The change in printf_hack.h might require some explanation: without it, my C++ compiler whines that the function is unused. There's not so many call sites that "inline" is going to cost much, and besides all the callers are in test code that we really don't care about the size of. There's no actual bugs being fixed here, so I see no need to back-patch. Discussion: https://postgr.es/m/b517ec3918d645eb950505eac8dd434e@gaz-is.ru
35 lines
700 B
C
35 lines
700 B
C
/*
|
|
* src/pl/plpython/plpy_subxactobject.h
|
|
*/
|
|
|
|
#ifndef PLPY_SUBXACTOBJECT
|
|
#define PLPY_SUBXACTOBJECT
|
|
|
|
#include "nodes/pg_list.h"
|
|
#include "utils/resowner.h"
|
|
|
|
#include "plpython.h"
|
|
|
|
/* a list of nested explicit subtransactions */
|
|
extern List *explicit_subtransactions;
|
|
|
|
|
|
typedef struct PLySubtransactionObject
|
|
{
|
|
PyObject_HEAD
|
|
bool started;
|
|
bool exited;
|
|
} PLySubtransactionObject;
|
|
|
|
/* explicit subtransaction data */
|
|
typedef struct PLySubtransactionData
|
|
{
|
|
MemoryContext oldcontext;
|
|
ResourceOwner oldowner;
|
|
} PLySubtransactionData;
|
|
|
|
extern void PLy_subtransaction_init_type(void);
|
|
extern PyObject *PLy_subtransaction_new(PyObject *self, PyObject *unused);
|
|
|
|
#endif /* PLPY_SUBXACTOBJECT */
|