From e8d78581bb864369035c736a82ecfb57482a1a09 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Mon, 12 Sep 2022 19:57:07 +0200 Subject: Revert "Convert *GetDatum() and DatumGet*() macros to inline functions" This reverts commit 595836e99bf1ee6d43405b885fb69bb8c6d3ee23. It has problems when USE_FLOAT8_BYVAL is off. --- src/include/utils/xml.h | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'src/include/utils/xml.h') diff --git a/src/include/utils/xml.h b/src/include/utils/xml.h index c71174d2041..6620a626191 100644 --- a/src/include/utils/xml.h +++ b/src/include/utils/xml.h @@ -47,17 +47,8 @@ typedef enum /* struct PgXmlErrorContext is private to xml.c */ typedef struct PgXmlErrorContext PgXmlErrorContext; -static inline xmltype * -DatumGetXmlP(Datum X) -{ - return (xmltype *) PG_DETOAST_DATUM(X); -} - -static inline Datum -XmlPGetDatum(const xmltype *X) -{ - return PointerGetDatum(X); -} +#define DatumGetXmlP(X) ((xmltype *) PG_DETOAST_DATUM(X)) +#define XmlPGetDatum(X) PointerGetDatum(X) #define PG_GETARG_XML_P(n) DatumGetXmlP(PG_GETARG_DATUM(n)) #define PG_RETURN_XML_P(x) PG_RETURN_POINTER(x) -- cgit v1.2.3