mirror of https://github.com/postgres/postgres
Remove code not previously enabled with USE_NEW_DATE and USE_NEW_TIME
#defines.
This commit is contained in:
parent
742425447d
commit
45409f0cdd
|
@ -6,7 +6,7 @@
|
|||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: builtins.h,v 1.18 1997/05/14 04:33:41 thomas Exp $
|
||||
* $Id: builtins.h,v 1.19 1997/06/23 15:03:38 thomas Exp $
|
||||
*
|
||||
* NOTES
|
||||
* This should normally only be included by fmgr.h.
|
||||
|
@ -481,8 +481,6 @@ extern struct varlena *byteaSetByte(struct varlena *v, int32 n, int32 newByte);
|
|||
extern struct varlena *byteaSetBit(struct varlena *v, int32 n, int32 newBit);
|
||||
|
||||
/* datetime.c */
|
||||
#if USE_NEW_DATE
|
||||
|
||||
extern DateADT date_in(char *datestr);
|
||||
extern char *date_out(DateADT dateVal);
|
||||
extern bool date_eq(DateADT dateVal1, DateADT dateVal2);
|
||||
|
@ -502,29 +500,6 @@ extern DateADT datetime_date(DateTime *datetime);
|
|||
extern DateTime *datetime_datetime(DateADT date, TimeADT *time);
|
||||
extern DateADT abstime_date(AbsoluteTime abstime);
|
||||
|
||||
#else
|
||||
|
||||
extern int4 date_in(char *datestr);
|
||||
extern char *date_out(int4 dateVal);
|
||||
extern bool date_eq(int4 dateVal1, int4 dateVal2);
|
||||
extern bool date_ne(int4 dateVal1, int4 dateVal2);
|
||||
extern bool date_lt(int4 dateVal1, int4 dateVal2);
|
||||
extern bool date_le(int4 dateVal1, int4 dateVal2);
|
||||
extern bool date_gt(int4 dateVal1, int4 dateVal2);
|
||||
extern bool date_ge(int4 dateVal1, int4 dateVal2);
|
||||
extern int date_cmp(int4 dateVal1, int4 dateVal2);
|
||||
extern int4 date_larger(int4 dateVal1, int4 dateVal2);
|
||||
extern int4 date_smaller(int4 dateVal1, int4 dateVal2);
|
||||
extern int32 date_mi(int4 dateVal1, int4 dateVal2);
|
||||
extern int4 date_pli(int4 dateVal, int32 days);
|
||||
extern int4 date_mii(int4 dateVal, int32 days);
|
||||
extern DateTime *date_datetime(int4 date);
|
||||
extern int4 datetime_date(DateTime *datetime);
|
||||
extern DateTime *datetime_datetime(int4 date, TimeADT *time);
|
||||
extern int4 abstime_date(AbsoluteTime abstime);
|
||||
|
||||
#endif
|
||||
|
||||
extern TimeADT *time_in(char *timestr);
|
||||
extern char *time_out(TimeADT *time);
|
||||
extern bool time_eq(TimeADT *time1, TimeADT *time2);
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: datetime.h,v 1.2 1997/03/14 23:33:21 scrappy Exp $
|
||||
* $Id: datetime.h,v 1.3 1997/06/23 15:03:41 thomas Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
|
@ -15,34 +15,8 @@
|
|||
|
||||
#include "utils/dt.h"
|
||||
|
||||
#if USE_NEW_DATE
|
||||
|
||||
typedef int32 DateADT;
|
||||
|
||||
#else
|
||||
|
||||
/* these things look like structs, but we pass them by value so be careful
|
||||
For example, passing an int -> DateADT is not portable! */
|
||||
typedef struct DateADT {
|
||||
char day;
|
||||
char month;
|
||||
short year;
|
||||
} DateADT;
|
||||
|
||||
#endif
|
||||
|
||||
#if USE_NEW_TIME
|
||||
|
||||
typedef float8 TimeADT;
|
||||
|
||||
#else
|
||||
|
||||
typedef struct TimeADT {
|
||||
short hr;
|
||||
short min;
|
||||
float sec;
|
||||
} TimeADT;
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* DATETIME_H */
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: dt.h,v 1.11 1997/06/20 17:15:00 thomas Exp $
|
||||
* $Id: dt.h,v 1.12 1997/06/23 15:03:45 thomas Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
|
@ -36,15 +36,6 @@ typedef struct {
|
|||
} TimeSpan;
|
||||
|
||||
|
||||
/*
|
||||
* USE_NEW_DATE enables a more efficient Julian day-based date type.
|
||||
* USE_NEW_TIME enables a more efficient double-based time type.
|
||||
*/
|
||||
|
||||
#define USE_NEW_DATE 1
|
||||
#define USE_NEW_TIME 1
|
||||
|
||||
|
||||
/* ----------------------------------------------------------------
|
||||
* time types + support macros
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue