aboutsummaryrefslogtreecommitdiff
path: root/src/include/executor/executor.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/executor/executor.h')
-rw-r--r--src/include/executor/executor.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h
index cc2e49efafc..1eb158440b1 100644
--- a/src/include/executor/executor.h
+++ b/src/include/executor/executor.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/executor/executor.h,v 1.107 2004/03/02 18:56:15 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/executor/executor.h,v 1.108 2004/03/17 01:02:24 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -17,17 +17,26 @@
#include "executor/execdesc.h"
-/* ----------------
- * TupIsNull
+/*
+ * TupIsNull
*
* This is used mainly to detect when there are no more
* tuples to process.
- * ----------------
*/
/* return: true if tuple in slot is NULL, slot is slot to test */
#define TupIsNull(slot) \
((slot) == NULL || (slot)->val == NULL)
+
+/*
+ * ExecEvalExpr was formerly a function containing a switch statement;
+ * now it's just a macro invoking the function pointed to by an ExprState
+ * node. Beware of double evaluation of the ExprState argument!
+ */
+#define ExecEvalExpr(expr, econtext, isNull, isDone) \
+ ((*(expr)->evalfunc) (expr, econtext, isNull, isDone))
+
+
/*
* prototypes from functions in execAmi.c
*/
@@ -125,8 +134,6 @@ extern Tuplestorestate *ExecMakeTableFunctionResult(ExprState *funcexpr,
ExprContext *econtext,
TupleDesc expectedDesc,
TupleDesc *returnDesc);
-extern Datum ExecEvalExpr(ExprState *expression, ExprContext *econtext,
- bool *isNull, ExprDoneCond *isDone);
extern Datum ExecEvalExprSwitchContext(ExprState *expression, ExprContext *econtext,
bool *isNull, ExprDoneCond *isDone);
extern ExprState *ExecInitExpr(Expr *node, PlanState *parent);