Skip to content
Snippets Groups Projects
Select Git revision
  • benchmark-tools
  • postgres-lambda
  • master default
  • REL9_4_25
  • REL9_5_20
  • REL9_6_16
  • REL_10_11
  • REL_11_6
  • REL_12_1
  • REL_12_0
  • REL_12_RC1
  • REL_12_BETA4
  • REL9_4_24
  • REL9_5_19
  • REL9_6_15
  • REL_10_10
  • REL_11_5
  • REL_12_BETA3
  • REL9_4_23
  • REL9_5_18
  • REL9_6_14
  • REL_10_9
  • REL_11_4
23 results

postgres.h

Blame
  • postgres.h 4.76 KiB
    /*-------------------------------------------------------------------------
     *
     * postgres.h--
     *	  definition of (and support for) postgres system types.
     * this file is included by almost every .c in the system
     *
     * Copyright (c) 1995, Regents of the University of California
     *
     * $Id: postgres.h,v 1.9 1997/09/08 21:50:28 momjian Exp $
     *
     *-------------------------------------------------------------------------
     */
    /*
     *	 NOTES
     *		this file will eventually contain the definitions for the
     *		following (and perhaps other) system types:
     *
     *				int2	   int4		  float4	   float8
     *				Oid		   regproc	  RegProcedure
     *				aclitem
     *				struct varlena
     *				char8	   char16	   int28	  oid8
     *				bytea	   text
     *				NameData   Name
     *				oidint4    oidint2	  oidname
     *
     *	 TABLE OF CONTENTS
     *		1)		simple type definitions
     *		2)		varlena and array types
     *		3)		TransactionId and CommandId
     *		4)		genbki macros used by catalog/pg_xxx.h files
     *		5)		random CSIGNBIT, MAXPGPATH, STATUS macros
     *
     * ----------------------------------------------------------------
     */
    #ifndef POSTGRES_H
    #define POSTGRES_H
    
    #include "postgres_ext.h"
    #include "config.h"
    #include "c.h"
    #include "utils/elog.h"
    #include "utils/palloc.h"
    
    /* ----------------------------------------------------------------
     *				Section 1:	simple type definitions
     * ----------------------------------------------------------------
     */
    
    typedef int16 int2;
    typedef int32 int4;
    typedef float float4;
    typedef double float8;
    
    typedef int4 aclitem;
    
    #define InvalidOid		0
    #define OidIsValid(objectId)  ((bool) (objectId != InvalidOid))
    
    /* unfortunately, both regproc and RegProcedure are used */
    typedef Oid regproc;
    typedef Oid RegProcedure;
    
    /* ptr to func returning (char *) */
    typedef char *((*func_ptr) ());
    
    
    #define RegProcedureIsValid(p)	OidIsValid(p)
    
    /* ----------------------------------------------------------------