1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-02 04:21:28 +03:00

Another pgindent run with lib typedefs added.

This commit is contained in:
Bruce Momjian
2004-08-30 02:54:42 +00:00
parent 166300f318
commit 15d3f9f6b7
53 changed files with 1036 additions and 989 deletions

View File

@@ -33,7 +33,7 @@
* ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plperl/plperl.c,v 1.49 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plperl/plperl.c,v 1.50 2004/08/30 02:54:41 momjian Exp $
*
**********************************************************************/
@@ -88,7 +88,7 @@ typedef struct plperl_proc_desc
Oid arg_typioparam[FUNC_MAX_ARGS];
bool arg_is_rowtype[FUNC_MAX_ARGS];
SV *reference;
} plperl_proc_desc;
} plperl_proc_desc;
/**********************************************************************
@@ -275,7 +275,7 @@ plperl_safe_init(void)
* turn a tuple into a hash expression and add it to a list
**********************************************************************/
static void
plperl_sv_add_tuple_value(SV * rv, HeapTuple tuple, TupleDesc tupdesc)
plperl_sv_add_tuple_value(SV *rv, HeapTuple tuple, TupleDesc tupdesc)
{
int i;
char *value;
@@ -384,7 +384,7 @@ plperl_trigger_build_args(FunctionCallInfo fcinfo)
* check return value from plperl function
**********************************************************************/
static int
plperl_is_set(SV * sv)
plperl_is_set(SV *sv)
{
int i = 0;
int len = 0;
@@ -432,7 +432,7 @@ plperl_is_set(SV * sv)
* extract a list of keys from a hash
**********************************************************************/
static AV *
plperl_get_keys(HV * hv)
plperl_get_keys(HV *hv)
{
AV *ret;
SV **svp;
@@ -458,7 +458,7 @@ plperl_get_keys(HV * hv)
* extract a given key (by index) from a list of keys
**********************************************************************/
static char *
plperl_get_key(AV * keys, int index)
plperl_get_key(AV *keys, int index)
{
SV **svp;
int len;
@@ -478,7 +478,7 @@ plperl_get_key(AV * keys, int index)
*
**********************************************************************/
static char *
plperl_get_elem(HV * hash, char *key)
plperl_get_elem(HV *hash, char *key)
{
SV **svp;
@@ -496,7 +496,7 @@ plperl_get_elem(HV * hash, char *key)
* set up the new tuple returned from a trigger
**********************************************************************/
static HeapTuple
plperl_modify_tuple(HV * hvTD, TriggerData *tdata, HeapTuple otup, Oid fn_oid)
plperl_modify_tuple(HV *hvTD, TriggerData *tdata, HeapTuple otup, Oid fn_oid)
{
SV **svp;
HV *hvNew;
@@ -700,8 +700,8 @@ plperl_create_sub(char *s, bool trusted)
*
**********************************************************************/
EXTERN_C void boot_DynaLoader(pTHX_ CV * cv);
EXTERN_C void boot_SPI(pTHX_ CV * cv);
EXTERN_C void boot_DynaLoader(pTHX_ CV *cv);
EXTERN_C void boot_SPI(pTHX_ CV *cv);
static void
plperl_init_shared_libs(pTHX)
@@ -717,7 +717,7 @@ plperl_init_shared_libs(pTHX)
* stored in the prodesc structure. massages the input parms properly
**********************************************************************/
static SV *
plperl_call_perl_func(plperl_proc_desc * desc, FunctionCallInfo fcinfo)
plperl_call_perl_func(plperl_proc_desc *desc, FunctionCallInfo fcinfo)
{
dSP;
SV *retval;
@@ -815,7 +815,7 @@ plperl_call_perl_func(plperl_proc_desc * desc, FunctionCallInfo fcinfo)
* through the RV stored in the prodesc structure. massages the input parms properly
**********************************************************************/
static SV *
plperl_call_perl_trigger_func(plperl_proc_desc * desc, FunctionCallInfo fcinfo, SV * td)
plperl_call_perl_trigger_func(plperl_proc_desc *desc, FunctionCallInfo fcinfo, SV *td)
{
dSP;
SV *retval;

View File

@@ -344,7 +344,7 @@ typedef NVTYPE NV;
#else
#if defined(USE_THREADS)
static SV *
newRV_noinc(SV * sv)
newRV_noinc(SV *sv)
{
SV *nsv = (SV *) newRV(sv);
@@ -367,7 +367,7 @@ newRV_noinc(SV * sv)
#if defined(NEED_newCONSTSUB)
static
#else
extern void newCONSTSUB(HV * stash, char *name, SV * sv);
extern void newCONSTSUB(HV *stash, char *name, SV *sv);
#endif
#if defined(NEED_newCONSTSUB) || defined(NEED_newCONSTSUB_GLOBAL)
@@ -545,7 +545,7 @@ SV *sv;
((SvFLAGS(sv) & (SVf_POK|SVf_UTF8)) == (SVf_POK) \
? ((lp = SvCUR(sv)), SvPVX(sv)) : my_sv_2pvbyte(aTHX_ sv, &lp))
static char *
my_sv_2pvbyte(pTHX_ register SV * sv, STRLEN * lp)
my_sv_2pvbyte(pTHX_ register SV *sv, STRLEN *lp)
{
sv_utf8_downgrade(sv, 0);
return SvPV(sv, *lp);
@@ -560,7 +560,7 @@ my_sv_2pvbyte(pTHX_ register SV * sv, STRLEN * lp)
((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
? SvPVX(sv) : sv_2pv_nolen(sv))
static char *
sv_2pv_nolen(pTHX_ register SV * sv)
sv_2pv_nolen(pTHX_ register SV *sv)
{
STRLEN n_a;

View File

@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.80 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_comp.c,v 1.81 2004/08/30 02:54:42 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
@@ -90,7 +90,7 @@ typedef struct plpgsql_hashent
{
PLpgSQL_func_hashkey key;
PLpgSQL_function *function;
} plpgsql_HashEnt;
} plpgsql_HashEnt;
#define FUNCS_PER_USER 128 /* initial table size */
@@ -102,7 +102,7 @@ typedef struct
{
const char *label;
int sqlerrstate;
} ExceptionLabelMap;
} ExceptionLabelMap;
static const ExceptionLabelMap exception_label_map[] = {
#include "plerrcodes.h"
@@ -116,7 +116,7 @@ static const ExceptionLabelMap exception_label_map[] = {
*/
static PLpgSQL_function *do_compile(FunctionCallInfo fcinfo,
HeapTuple procTup,
PLpgSQL_func_hashkey * hashkey,
PLpgSQL_func_hashkey *hashkey,
bool forValidator);
static void plpgsql_compile_error_callback(void *arg);
static char **fetchArgNames(HeapTuple procTup, int nargs);
@@ -124,12 +124,12 @@ static PLpgSQL_row *build_row_var(Oid classOid);
static PLpgSQL_type *build_datatype(HeapTuple typeTup, int32 typmod);
static void compute_function_hashkey(FunctionCallInfo fcinfo,
Form_pg_proc procStruct,
PLpgSQL_func_hashkey * hashkey,
PLpgSQL_func_hashkey *hashkey,
bool forValidator);
static PLpgSQL_function *plpgsql_HashTableLookup(PLpgSQL_func_hashkey * func_key);
static void plpgsql_HashTableInsert(PLpgSQL_function * function,
PLpgSQL_func_hashkey * func_key);
static void plpgsql_HashTableDelete(PLpgSQL_function * function);
static PLpgSQL_function *plpgsql_HashTableLookup(PLpgSQL_func_hashkey *func_key);
static void plpgsql_HashTableInsert(PLpgSQL_function *function,
PLpgSQL_func_hashkey *func_key);
static void plpgsql_HashTableDelete(PLpgSQL_function *function);
/*
* This routine is a crock, and so is everyplace that calls it. The problem
@@ -254,7 +254,7 @@ plpgsql_compile(FunctionCallInfo fcinfo, bool forValidator)
static PLpgSQL_function *
do_compile(FunctionCallInfo fcinfo,
HeapTuple procTup,
PLpgSQL_func_hashkey * hashkey,
PLpgSQL_func_hashkey *hashkey,
bool forValidator)
{
Form_pg_proc procStruct = (Form_pg_proc) GETSTRUCT(procTup);
@@ -1437,7 +1437,7 @@ plpgsql_parse_dblwordrowtype(char *word)
* to the current datum array, and optionally to the current namespace.
*/
PLpgSQL_variable *
plpgsql_build_variable(char *refname, int lineno, PLpgSQL_type * dtype,
plpgsql_build_variable(char *refname, int lineno, PLpgSQL_type *dtype,
bool add2namespace)
{
PLpgSQL_variable *result;
@@ -1789,7 +1789,7 @@ plpgsql_parse_err_condition(char *condname)
* ----------
*/
void
plpgsql_adddatum(PLpgSQL_datum * new)
plpgsql_adddatum(PLpgSQL_datum *new)
{
if (plpgsql_nDatums == datums_alloc)
{
@@ -1865,7 +1865,7 @@ plpgsql_add_initdatums(int **varnos)
static void
compute_function_hashkey(FunctionCallInfo fcinfo,
Form_pg_proc procStruct,
PLpgSQL_func_hashkey * hashkey,
PLpgSQL_func_hashkey *hashkey,
bool forValidator)
{
int i;
@@ -1944,7 +1944,7 @@ plpgsql_HashTableInit(void)
}
static PLpgSQL_function *
plpgsql_HashTableLookup(PLpgSQL_func_hashkey * func_key)
plpgsql_HashTableLookup(PLpgSQL_func_hashkey *func_key)
{
plpgsql_HashEnt *hentry;
@@ -1959,8 +1959,8 @@ plpgsql_HashTableLookup(PLpgSQL_func_hashkey * func_key)
}
static void
plpgsql_HashTableInsert(PLpgSQL_function * function,
PLpgSQL_func_hashkey * func_key)
plpgsql_HashTableInsert(PLpgSQL_function *function,
PLpgSQL_func_hashkey *func_key)
{
plpgsql_HashEnt *hentry;
bool found;
@@ -1982,7 +1982,7 @@ plpgsql_HashTableInsert(PLpgSQL_function * function,
}
static void
plpgsql_HashTableDelete(PLpgSQL_function * function)
plpgsql_HashTableDelete(PLpgSQL_function *function)
{
plpgsql_HashEnt *hentry;

View File

@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.117 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.118 2004/08/30 02:54:42 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
@@ -74,98 +74,98 @@ static PLpgSQL_expr *active_simple_exprs = NULL;
* Local function forward declarations
************************************************************/
static void plpgsql_exec_error_callback(void *arg);
static PLpgSQL_var *copy_var(PLpgSQL_var * var);
static PLpgSQL_rec *copy_rec(PLpgSQL_rec * rec);
static PLpgSQL_var *copy_var(PLpgSQL_var *var);
static PLpgSQL_rec *copy_rec(PLpgSQL_rec *rec);
static int exec_stmt_block(PLpgSQL_execstate * estate,
PLpgSQL_stmt_block * block);
static int exec_stmts(PLpgSQL_execstate * estate,
PLpgSQL_stmts * stmts);
static int exec_stmt(PLpgSQL_execstate * estate,
PLpgSQL_stmt * stmt);
static int exec_stmt_assign(PLpgSQL_execstate * estate,
PLpgSQL_stmt_assign * stmt);
static int exec_stmt_perform(PLpgSQL_execstate * estate,
PLpgSQL_stmt_perform * stmt);
static int exec_stmt_getdiag(PLpgSQL_execstate * estate,
PLpgSQL_stmt_getdiag * stmt);
static int exec_stmt_if(PLpgSQL_execstate * estate,
PLpgSQL_stmt_if * stmt);
static int exec_stmt_loop(PLpgSQL_execstate * estate,
PLpgSQL_stmt_loop * stmt);
static int exec_stmt_while(PLpgSQL_execstate * estate,
PLpgSQL_stmt_while * stmt);
static int exec_stmt_fori(PLpgSQL_execstate * estate,
PLpgSQL_stmt_fori * stmt);
static int exec_stmt_fors(PLpgSQL_execstate * estate,
PLpgSQL_stmt_fors * stmt);
static int exec_stmt_select(PLpgSQL_execstate * estate,
PLpgSQL_stmt_select * stmt);
static int exec_stmt_open(PLpgSQL_execstate * estate,
PLpgSQL_stmt_open * stmt);
static int exec_stmt_fetch(PLpgSQL_execstate * estate,
PLpgSQL_stmt_fetch * stmt);
static int exec_stmt_close(PLpgSQL_execstate * estate,
PLpgSQL_stmt_close * stmt);
static int exec_stmt_exit(PLpgSQL_execstate * estate,
PLpgSQL_stmt_exit * stmt);
static int exec_stmt_return(PLpgSQL_execstate * estate,
PLpgSQL_stmt_return * stmt);
static int exec_stmt_return_next(PLpgSQL_execstate * estate,
PLpgSQL_stmt_return_next * stmt);
static int exec_stmt_raise(PLpgSQL_execstate * estate,
PLpgSQL_stmt_raise * stmt);
static int exec_stmt_execsql(PLpgSQL_execstate * estate,
PLpgSQL_stmt_execsql * stmt);
static int exec_stmt_dynexecute(PLpgSQL_execstate * estate,
PLpgSQL_stmt_dynexecute * stmt);
static int exec_stmt_dynfors(PLpgSQL_execstate * estate,
PLpgSQL_stmt_dynfors * stmt);
static int exec_stmt_block(PLpgSQL_execstate *estate,
PLpgSQL_stmt_block *block);
static int exec_stmts(PLpgSQL_execstate *estate,
PLpgSQL_stmts *stmts);
static int exec_stmt(PLpgSQL_execstate *estate,
PLpgSQL_stmt *stmt);
static int exec_stmt_assign(PLpgSQL_execstate *estate,
PLpgSQL_stmt_assign *stmt);
static int exec_stmt_perform(PLpgSQL_execstate *estate,
PLpgSQL_stmt_perform *stmt);
static int exec_stmt_getdiag(PLpgSQL_execstate *estate,
PLpgSQL_stmt_getdiag *stmt);
static int exec_stmt_if(PLpgSQL_execstate *estate,
PLpgSQL_stmt_if *stmt);
static int exec_stmt_loop(PLpgSQL_execstate *estate,
PLpgSQL_stmt_loop *stmt);
static int exec_stmt_while(PLpgSQL_execstate *estate,
PLpgSQL_stmt_while *stmt);
static int exec_stmt_fori(PLpgSQL_execstate *estate,
PLpgSQL_stmt_fori *stmt);
static int exec_stmt_fors(PLpgSQL_execstate *estate,
PLpgSQL_stmt_fors *stmt);
static int exec_stmt_select(PLpgSQL_execstate *estate,
PLpgSQL_stmt_select *stmt);
static int exec_stmt_open(PLpgSQL_execstate *estate,
PLpgSQL_stmt_open *stmt);
static int exec_stmt_fetch(PLpgSQL_execstate *estate,
PLpgSQL_stmt_fetch *stmt);
static int exec_stmt_close(PLpgSQL_execstate *estate,
PLpgSQL_stmt_close *stmt);
static int exec_stmt_exit(PLpgSQL_execstate *estate,
PLpgSQL_stmt_exit *stmt);
static int exec_stmt_return(PLpgSQL_execstate *estate,
PLpgSQL_stmt_return *stmt);
static int exec_stmt_return_next(PLpgSQL_execstate *estate,
PLpgSQL_stmt_return_next *stmt);
static int exec_stmt_raise(PLpgSQL_execstate *estate,
PLpgSQL_stmt_raise *stmt);
static int exec_stmt_execsql(PLpgSQL_execstate *estate,
PLpgSQL_stmt_execsql *stmt);
static int exec_stmt_dynexecute(PLpgSQL_execstate *estate,
PLpgSQL_stmt_dynexecute *stmt);
static int exec_stmt_dynfors(PLpgSQL_execstate *estate,
PLpgSQL_stmt_dynfors *stmt);
static void plpgsql_estate_setup(PLpgSQL_execstate * estate,
PLpgSQL_function * func,
static void plpgsql_estate_setup(PLpgSQL_execstate *estate,
PLpgSQL_function *func,
ReturnSetInfo *rsi);
static void exec_eval_cleanup(PLpgSQL_execstate * estate);
static void exec_eval_cleanup(PLpgSQL_execstate *estate);
static void exec_prepare_plan(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr);
static void exec_prepare_plan(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr);
static bool exec_simple_check_node(Node *node);
static void exec_simple_check_plan(PLpgSQL_expr * expr);
static Datum exec_eval_simple_expr(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
static void exec_simple_check_plan(PLpgSQL_expr *expr);
static Datum exec_eval_simple_expr(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull,
Oid *rettype);
static void exec_assign_expr(PLpgSQL_execstate * estate,
PLpgSQL_datum * target,
PLpgSQL_expr * expr);
static void exec_assign_value(PLpgSQL_execstate * estate,
PLpgSQL_datum * target,
static void exec_assign_expr(PLpgSQL_execstate *estate,
PLpgSQL_datum *target,
PLpgSQL_expr *expr);
static void exec_assign_value(PLpgSQL_execstate *estate,
PLpgSQL_datum *target,
Datum value, Oid valtype, bool *isNull);
static void exec_eval_datum(PLpgSQL_execstate * estate,
PLpgSQL_datum * datum,
static void exec_eval_datum(PLpgSQL_execstate *estate,
PLpgSQL_datum *datum,
Oid expectedtypeid,
Oid *typeid,
Datum *value,
bool *isnull);
static int exec_eval_integer(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
static int exec_eval_integer(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull);
static bool exec_eval_boolean(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
static bool exec_eval_boolean(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull);
static Datum exec_eval_expr(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
static Datum exec_eval_expr(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull,
Oid *rettype);
static int exec_run_select(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr, int maxtuples, Portal *portalP);
static void exec_move_row(PLpgSQL_execstate * estate,
PLpgSQL_rec * rec,
PLpgSQL_row * row,
static int exec_run_select(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr, int maxtuples, Portal *portalP);
static void exec_move_row(PLpgSQL_execstate *estate,
PLpgSQL_rec *rec,
PLpgSQL_row *row,
HeapTuple tup, TupleDesc tupdesc);
static HeapTuple make_tuple_from_row(PLpgSQL_execstate * estate,
PLpgSQL_row * row,
static HeapTuple make_tuple_from_row(PLpgSQL_execstate *estate,
PLpgSQL_row *row,
TupleDesc tupdesc);
static char *convert_value_to_string(Datum value, Oid valtype);
static Datum exec_cast_value(Datum value, Oid valtype,
@@ -177,9 +177,9 @@ static Datum exec_cast_value(Datum value, Oid valtype,
static Datum exec_simple_cast_value(Datum value, Oid valtype,
Oid reqtype, int32 reqtypmod,
bool *isnull);
static void exec_init_tuple_store(PLpgSQL_execstate * estate);
static void exec_init_tuple_store(PLpgSQL_execstate *estate);
static bool compatible_tupdesc(TupleDesc td1, TupleDesc td2);
static void exec_set_found(PLpgSQL_execstate * estate, bool state);
static void exec_set_found(PLpgSQL_execstate *estate, bool state);
/* ----------
@@ -188,7 +188,7 @@ static void exec_set_found(PLpgSQL_execstate * estate, bool state);
* ----------
*/
Datum
plpgsql_exec_function(PLpgSQL_function * func, FunctionCallInfo fcinfo)
plpgsql_exec_function(PLpgSQL_function *func, FunctionCallInfo fcinfo)
{
PLpgSQL_execstate estate;
ErrorContextCallback plerrcontext;
@@ -438,7 +438,7 @@ plpgsql_exec_function(PLpgSQL_function * func, FunctionCallInfo fcinfo)
* ----------
*/
HeapTuple
plpgsql_exec_trigger(PLpgSQL_function * func,
plpgsql_exec_trigger(PLpgSQL_function *func,
TriggerData *trigdata)
{
PLpgSQL_execstate estate;
@@ -759,7 +759,7 @@ plpgsql_exec_error_callback(void *arg)
* ----------
*/
static PLpgSQL_var *
copy_var(PLpgSQL_var * var)
copy_var(PLpgSQL_var *var)
{
PLpgSQL_var *new = palloc(sizeof(PLpgSQL_var));
@@ -771,7 +771,7 @@ copy_var(PLpgSQL_var * var)
static PLpgSQL_rec *
copy_rec(PLpgSQL_rec * rec)
copy_rec(PLpgSQL_rec *rec)
{
PLpgSQL_rec *new = palloc(sizeof(PLpgSQL_rec));
@@ -786,7 +786,7 @@ copy_rec(PLpgSQL_rec * rec)
static bool
exception_matches_conditions(ErrorData *edata, PLpgSQL_condition * cond)
exception_matches_conditions(ErrorData *edata, PLpgSQL_condition *cond)
{
for (; cond != NULL; cond = cond->next)
{
@@ -818,7 +818,7 @@ exception_matches_conditions(ErrorData *edata, PLpgSQL_condition * cond)
* ----------
*/
static int
exec_stmt_block(PLpgSQL_execstate * estate, PLpgSQL_stmt_block * block)
exec_stmt_block(PLpgSQL_execstate *estate, PLpgSQL_stmt_block *block)
{
volatile int rc = -1;
int i;
@@ -912,7 +912,7 @@ exec_stmt_block(PLpgSQL_execstate * estate, PLpgSQL_stmt_block * block)
SPI_result_code_string(xrc));
PG_TRY();
rc = exec_stmts(estate, block->body);
rc = exec_stmts(estate, block->body);
PG_CATCH();
{
ErrorData *edata;
@@ -1006,7 +1006,7 @@ exec_stmt_block(PLpgSQL_execstate * estate, PLpgSQL_stmt_block * block)
* ----------
*/
static int
exec_stmts(PLpgSQL_execstate * estate, PLpgSQL_stmts * stmts)
exec_stmts(PLpgSQL_execstate *estate, PLpgSQL_stmts *stmts)
{
int rc;
int i;
@@ -1028,7 +1028,7 @@ exec_stmts(PLpgSQL_execstate * estate, PLpgSQL_stmts * stmts)
* ----------
*/
static int
exec_stmt(PLpgSQL_execstate * estate, PLpgSQL_stmt * stmt)
exec_stmt(PLpgSQL_execstate *estate, PLpgSQL_stmt *stmt)
{
PLpgSQL_stmt *save_estmt;
int rc = -1;
@@ -1137,7 +1137,7 @@ exec_stmt(PLpgSQL_execstate * estate, PLpgSQL_stmt * stmt)
* ----------
*/
static int
exec_stmt_assign(PLpgSQL_execstate * estate, PLpgSQL_stmt_assign * stmt)
exec_stmt_assign(PLpgSQL_execstate *estate, PLpgSQL_stmt_assign *stmt)
{
Assert(stmt->varno >= 0);
@@ -1153,7 +1153,7 @@ exec_stmt_assign(PLpgSQL_execstate * estate, PLpgSQL_stmt_assign * stmt)
* ----------
*/
static int
exec_stmt_perform(PLpgSQL_execstate * estate, PLpgSQL_stmt_perform * stmt)
exec_stmt_perform(PLpgSQL_execstate *estate, PLpgSQL_stmt_perform *stmt)
{
PLpgSQL_expr *expr = stmt->expr;
int rc;
@@ -1183,7 +1183,7 @@ exec_stmt_perform(PLpgSQL_execstate * estate, PLpgSQL_stmt_perform * stmt)
* ----------
*/
static int
exec_stmt_getdiag(PLpgSQL_execstate * estate, PLpgSQL_stmt_getdiag * stmt)
exec_stmt_getdiag(PLpgSQL_execstate *estate, PLpgSQL_stmt_getdiag *stmt)
{
int i;
PLpgSQL_datum *var;
@@ -1233,7 +1233,7 @@ exec_stmt_getdiag(PLpgSQL_execstate * estate, PLpgSQL_stmt_getdiag * stmt)
* ----------
*/
static int
exec_stmt_if(PLpgSQL_execstate * estate, PLpgSQL_stmt_if * stmt)
exec_stmt_if(PLpgSQL_execstate *estate, PLpgSQL_stmt_if *stmt)
{
bool value;
bool isnull = false;
@@ -1262,7 +1262,7 @@ exec_stmt_if(PLpgSQL_execstate * estate, PLpgSQL_stmt_if * stmt)
* ----------
*/
static int
exec_stmt_loop(PLpgSQL_execstate * estate, PLpgSQL_stmt_loop * stmt)
exec_stmt_loop(PLpgSQL_execstate *estate, PLpgSQL_stmt_loop *stmt)
{
int rc;
@@ -1304,7 +1304,7 @@ exec_stmt_loop(PLpgSQL_execstate * estate, PLpgSQL_stmt_loop * stmt)
* ----------
*/
static int
exec_stmt_while(PLpgSQL_execstate * estate, PLpgSQL_stmt_while * stmt)
exec_stmt_while(PLpgSQL_execstate *estate, PLpgSQL_stmt_while *stmt)
{
bool value;
bool isnull = false;
@@ -1354,7 +1354,7 @@ exec_stmt_while(PLpgSQL_execstate * estate, PLpgSQL_stmt_while * stmt)
* ----------
*/
static int
exec_stmt_fori(PLpgSQL_execstate * estate, PLpgSQL_stmt_fori * stmt)
exec_stmt_fori(PLpgSQL_execstate *estate, PLpgSQL_stmt_fori *stmt)
{
PLpgSQL_var *var;
Datum value;
@@ -1474,7 +1474,7 @@ exec_stmt_fori(PLpgSQL_execstate * estate, PLpgSQL_stmt_fori * stmt)
* ----------
*/
static int
exec_stmt_fors(PLpgSQL_execstate * estate, PLpgSQL_stmt_fors * stmt)
exec_stmt_fors(PLpgSQL_execstate *estate, PLpgSQL_stmt_fors *stmt)
{
PLpgSQL_rec *rec = NULL;
PLpgSQL_row *row = NULL;
@@ -1604,7 +1604,7 @@ exec_stmt_fors(PLpgSQL_execstate * estate, PLpgSQL_stmt_fors * stmt)
* ----------
*/
static int
exec_stmt_select(PLpgSQL_execstate * estate, PLpgSQL_stmt_select * stmt)
exec_stmt_select(PLpgSQL_execstate *estate, PLpgSQL_stmt_select *stmt)
{
PLpgSQL_rec *rec = NULL;
PLpgSQL_row *row = NULL;
@@ -1661,7 +1661,7 @@ exec_stmt_select(PLpgSQL_execstate * estate, PLpgSQL_stmt_select * stmt)
* ----------
*/
static int
exec_stmt_exit(PLpgSQL_execstate * estate, PLpgSQL_stmt_exit * stmt)
exec_stmt_exit(PLpgSQL_execstate *estate, PLpgSQL_stmt_exit *stmt)
{
/*
* If the exit has a condition, check that it's true
@@ -1688,7 +1688,7 @@ exec_stmt_exit(PLpgSQL_execstate * estate, PLpgSQL_stmt_exit * stmt)
* ----------
*/
static int
exec_stmt_return(PLpgSQL_execstate * estate, PLpgSQL_stmt_return * stmt)
exec_stmt_return(PLpgSQL_execstate *estate, PLpgSQL_stmt_return *stmt)
{
/*
* If processing a set-returning PL/PgSQL function, the final RETURN
@@ -1772,8 +1772,8 @@ exec_stmt_return(PLpgSQL_execstate * estate, PLpgSQL_stmt_return * stmt)
* ----------
*/
static int
exec_stmt_return_next(PLpgSQL_execstate * estate,
PLpgSQL_stmt_return_next * stmt)
exec_stmt_return_next(PLpgSQL_execstate *estate,
PLpgSQL_stmt_return_next *stmt)
{
TupleDesc tupdesc;
int natts;
@@ -1873,7 +1873,7 @@ exec_stmt_return_next(PLpgSQL_execstate * estate,
}
static void
exec_init_tuple_store(PLpgSQL_execstate * estate)
exec_init_tuple_store(PLpgSQL_execstate *estate)
{
ReturnSetInfo *rsi = estate->rsi;
MemoryContext oldcxt;
@@ -1902,7 +1902,7 @@ exec_init_tuple_store(PLpgSQL_execstate * estate)
* ----------
*/
static int
exec_stmt_raise(PLpgSQL_execstate * estate, PLpgSQL_stmt_raise * stmt)
exec_stmt_raise(PLpgSQL_execstate *estate, PLpgSQL_stmt_raise *stmt)
{
Oid paramtypeid;
Datum paramvalue;
@@ -1972,8 +1972,8 @@ exec_stmt_raise(PLpgSQL_execstate * estate, PLpgSQL_stmt_raise * stmt)
* ----------
*/
static void
plpgsql_estate_setup(PLpgSQL_execstate * estate,
PLpgSQL_function * func,
plpgsql_estate_setup(PLpgSQL_execstate *estate,
PLpgSQL_function *func,
ReturnSetInfo *rsi)
{
estate->retval = (Datum) 0;
@@ -2017,7 +2017,7 @@ plpgsql_estate_setup(PLpgSQL_execstate * estate,
* ----------
*/
static void
exec_eval_cleanup(PLpgSQL_execstate * estate)
exec_eval_cleanup(PLpgSQL_execstate *estate)
{
/* Clear result of a full SPI_exec */
if (estate->eval_tuptable != NULL)
@@ -2035,8 +2035,8 @@ exec_eval_cleanup(PLpgSQL_execstate * estate)
* ----------
*/
static void
exec_prepare_plan(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr)
exec_prepare_plan(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr)
{
int i;
_SPI_plan *spi_plan;
@@ -2104,8 +2104,8 @@ exec_prepare_plan(PLpgSQL_execstate * estate,
* ----------
*/
static int
exec_stmt_execsql(PLpgSQL_execstate * estate,
PLpgSQL_stmt_execsql * stmt)
exec_stmt_execsql(PLpgSQL_execstate *estate,
PLpgSQL_stmt_execsql *stmt)
{
int i;
Datum *values;
@@ -2195,8 +2195,8 @@ exec_stmt_execsql(PLpgSQL_execstate * estate,
* ----------
*/
static int
exec_stmt_dynexecute(PLpgSQL_execstate * estate,
PLpgSQL_stmt_dynexecute * stmt)
exec_stmt_dynexecute(PLpgSQL_execstate *estate,
PLpgSQL_stmt_dynexecute *stmt)
{
Datum query;
bool isnull = false;
@@ -2309,7 +2309,7 @@ exec_stmt_dynexecute(PLpgSQL_execstate * estate,
* ----------
*/
static int
exec_stmt_dynfors(PLpgSQL_execstate * estate, PLpgSQL_stmt_dynfors * stmt)
exec_stmt_dynfors(PLpgSQL_execstate *estate, PLpgSQL_stmt_dynfors *stmt)
{
Datum query;
bool isnull = false;
@@ -2469,7 +2469,7 @@ exec_stmt_dynfors(PLpgSQL_execstate * estate, PLpgSQL_stmt_dynfors * stmt)
* ----------
*/
static int
exec_stmt_open(PLpgSQL_execstate * estate, PLpgSQL_stmt_open * stmt)
exec_stmt_open(PLpgSQL_execstate *estate, PLpgSQL_stmt_open *stmt)
{
PLpgSQL_var *curvar = NULL;
char *curname = NULL;
@@ -2673,7 +2673,7 @@ exec_stmt_open(PLpgSQL_execstate * estate, PLpgSQL_stmt_open * stmt)
* ----------
*/
static int
exec_stmt_fetch(PLpgSQL_execstate * estate, PLpgSQL_stmt_fetch * stmt)
exec_stmt_fetch(PLpgSQL_execstate *estate, PLpgSQL_stmt_fetch *stmt)
{
PLpgSQL_var *curvar = NULL;
PLpgSQL_rec *rec = NULL;
@@ -2746,7 +2746,7 @@ exec_stmt_fetch(PLpgSQL_execstate * estate, PLpgSQL_stmt_fetch * stmt)
* ----------
*/
static int
exec_stmt_close(PLpgSQL_execstate * estate, PLpgSQL_stmt_close * stmt)
exec_stmt_close(PLpgSQL_execstate *estate, PLpgSQL_stmt_close *stmt)
{
PLpgSQL_var *curvar = NULL;
Portal portal;
@@ -2786,8 +2786,8 @@ exec_stmt_close(PLpgSQL_execstate * estate, PLpgSQL_stmt_close * stmt)
* ----------
*/
static void
exec_assign_expr(PLpgSQL_execstate * estate, PLpgSQL_datum * target,
PLpgSQL_expr * expr)
exec_assign_expr(PLpgSQL_execstate *estate, PLpgSQL_datum *target,
PLpgSQL_expr *expr)
{
Datum value;
Oid valtype;
@@ -2804,8 +2804,8 @@ exec_assign_expr(PLpgSQL_execstate * estate, PLpgSQL_datum * target,
* ----------
*/
static void
exec_assign_value(PLpgSQL_execstate * estate,
PLpgSQL_datum * target,
exec_assign_value(PLpgSQL_execstate *estate,
PLpgSQL_datum *target,
Datum value, Oid valtype, bool *isNull)
{
switch (target->dtype)
@@ -3195,8 +3195,8 @@ exec_assign_value(PLpgSQL_execstate * estate,
* at the stored value in the case of pass-by-reference datatypes.
*/
static void
exec_eval_datum(PLpgSQL_execstate * estate,
PLpgSQL_datum * datum,
exec_eval_datum(PLpgSQL_execstate *estate,
PLpgSQL_datum *datum,
Oid expectedtypeid,
Oid *typeid,
Datum *value,
@@ -3348,8 +3348,8 @@ exec_eval_datum(PLpgSQL_execstate * estate,
* ----------
*/
static int
exec_eval_integer(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
exec_eval_integer(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull)
{
Datum exprdatum;
@@ -3370,8 +3370,8 @@ exec_eval_integer(PLpgSQL_execstate * estate,
* ----------
*/
static bool
exec_eval_boolean(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
exec_eval_boolean(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull)
{
Datum exprdatum;
@@ -3392,8 +3392,8 @@ exec_eval_boolean(PLpgSQL_execstate * estate,
* ----------
*/
static Datum
exec_eval_expr(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
exec_eval_expr(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull,
Oid *rettype)
{
@@ -3455,8 +3455,8 @@ exec_eval_expr(PLpgSQL_execstate * estate,
* ----------
*/
static int
exec_run_select(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr, int maxtuples, Portal *portalP)
exec_run_select(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr, int maxtuples, Portal *portalP)
{
int i;
Datum *values;
@@ -3535,8 +3535,8 @@ exec_run_select(PLpgSQL_execstate * estate,
* ----------
*/
static Datum
exec_eval_simple_expr(PLpgSQL_execstate * estate,
PLpgSQL_expr * expr,
exec_eval_simple_expr(PLpgSQL_execstate *estate,
PLpgSQL_expr *expr,
bool *isNull,
Oid *rettype)
{
@@ -3643,9 +3643,9 @@ exec_eval_simple_expr(PLpgSQL_execstate * estate,
* ----------
*/
static void
exec_move_row(PLpgSQL_execstate * estate,
PLpgSQL_rec * rec,
PLpgSQL_row * row,
exec_move_row(PLpgSQL_execstate *estate,
PLpgSQL_rec *rec,
PLpgSQL_row *row,
HeapTuple tup, TupleDesc tupdesc)
{
/*
@@ -3769,8 +3769,8 @@ exec_move_row(PLpgSQL_execstate * estate,
* ----------
*/
static HeapTuple
make_tuple_from_row(PLpgSQL_execstate * estate,
PLpgSQL_row * row,
make_tuple_from_row(PLpgSQL_execstate *estate,
PLpgSQL_row *row,
TupleDesc tupdesc)
{
int natts = tupdesc->natts;
@@ -4127,7 +4127,7 @@ exec_simple_check_node(Node *node)
* ----------
*/
static void
exec_simple_check_plan(PLpgSQL_expr * expr)
exec_simple_check_plan(PLpgSQL_expr *expr)
{
_SPI_plan *spi_plan = (_SPI_plan *) expr->plan;
Plan *plan;
@@ -4214,7 +4214,7 @@ compatible_tupdesc(TupleDesc td1, TupleDesc td2)
* ----------
*/
static void
exec_set_found(PLpgSQL_execstate * estate, bool state)
exec_set_found(PLpgSQL_execstate *estate, bool state)
{
PLpgSQL_var *var;

View File

@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_funcs.c,v 1.35 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_funcs.c,v 1.36 2004/08/30 02:54:42 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
@@ -56,7 +56,7 @@ static bool ns_localmode = false;
* ----------
*/
void
plpgsql_dstring_init(PLpgSQL_dstring * ds)
plpgsql_dstring_init(PLpgSQL_dstring *ds)
{
ds->value = palloc(ds->alloc = 512);
ds->used = 0;
@@ -69,7 +69,7 @@ plpgsql_dstring_init(PLpgSQL_dstring * ds)
* ----------
*/
void
plpgsql_dstring_free(PLpgSQL_dstring * ds)
plpgsql_dstring_free(PLpgSQL_dstring *ds)
{
pfree(ds->value);
}
@@ -80,7 +80,7 @@ plpgsql_dstring_free(PLpgSQL_dstring * ds)
* ----------
*/
void
plpgsql_dstring_append(PLpgSQL_dstring * ds, char *str)
plpgsql_dstring_append(PLpgSQL_dstring *ds, char *str)
{
int len = strlen(str);
int needed = ds->used + len + 1;
@@ -105,7 +105,7 @@ plpgsql_dstring_append(PLpgSQL_dstring * ds, char *str)
* ----------
*/
char *
plpgsql_dstring_get(PLpgSQL_dstring * ds)
plpgsql_dstring_get(PLpgSQL_dstring *ds)
{
return ds->value;
}
@@ -422,7 +422,7 @@ plpgsql_convert_ident(const char *s, char **output, int numidents)
* Statement type as a string, for use in error messages etc.
*/
const char *
plpgsql_stmt_typename(PLpgSQL_stmt * stmt)
plpgsql_stmt_typename(PLpgSQL_stmt *stmt)
{
switch (stmt->cmd_type)
{
@@ -478,28 +478,28 @@ plpgsql_stmt_typename(PLpgSQL_stmt * stmt)
static int dump_indent;
static void dump_ind();
static void dump_stmt(PLpgSQL_stmt * stmt);
static void dump_block(PLpgSQL_stmt_block * block);
static void dump_assign(PLpgSQL_stmt_assign * stmt);
static void dump_if(PLpgSQL_stmt_if * stmt);
static void dump_loop(PLpgSQL_stmt_loop * stmt);
static void dump_while(PLpgSQL_stmt_while * stmt);
static void dump_fori(PLpgSQL_stmt_fori * stmt);
static void dump_fors(PLpgSQL_stmt_fors * stmt);
static void dump_select(PLpgSQL_stmt_select * stmt);
static void dump_exit(PLpgSQL_stmt_exit * stmt);
static void dump_return(PLpgSQL_stmt_return * stmt);
static void dump_return_next(PLpgSQL_stmt_return_next * stmt);
static void dump_raise(PLpgSQL_stmt_raise * stmt);
static void dump_execsql(PLpgSQL_stmt_execsql * stmt);
static void dump_dynexecute(PLpgSQL_stmt_dynexecute * stmt);
static void dump_dynfors(PLpgSQL_stmt_dynfors * stmt);
static void dump_getdiag(PLpgSQL_stmt_getdiag * stmt);
static void dump_open(PLpgSQL_stmt_open * stmt);
static void dump_fetch(PLpgSQL_stmt_fetch * stmt);
static void dump_close(PLpgSQL_stmt_close * stmt);
static void dump_perform(PLpgSQL_stmt_perform * stmt);
static void dump_expr(PLpgSQL_expr * expr);
static void dump_stmt(PLpgSQL_stmt *stmt);
static void dump_block(PLpgSQL_stmt_block *block);
static void dump_assign(PLpgSQL_stmt_assign *stmt);
static void dump_if(PLpgSQL_stmt_if *stmt);
static void dump_loop(PLpgSQL_stmt_loop *stmt);
static void dump_while(PLpgSQL_stmt_while *stmt);
static void dump_fori(PLpgSQL_stmt_fori *stmt);
static void dump_fors(PLpgSQL_stmt_fors *stmt);
static void dump_select(PLpgSQL_stmt_select *stmt);
static void dump_exit(PLpgSQL_stmt_exit *stmt);
static void dump_return(PLpgSQL_stmt_return *stmt);
static void dump_return_next(PLpgSQL_stmt_return_next *stmt);
static void dump_raise(PLpgSQL_stmt_raise *stmt);
static void dump_execsql(PLpgSQL_stmt_execsql *stmt);
static void dump_dynexecute(PLpgSQL_stmt_dynexecute *stmt);
static void dump_dynfors(PLpgSQL_stmt_dynfors *stmt);
static void dump_getdiag(PLpgSQL_stmt_getdiag *stmt);
static void dump_open(PLpgSQL_stmt_open *stmt);
static void dump_fetch(PLpgSQL_stmt_fetch *stmt);
static void dump_close(PLpgSQL_stmt_close *stmt);
static void dump_perform(PLpgSQL_stmt_perform *stmt);
static void dump_expr(PLpgSQL_expr *expr);
static void
@@ -512,7 +512,7 @@ dump_ind()
}
static void
dump_stmt(PLpgSQL_stmt * stmt)
dump_stmt(PLpgSQL_stmt *stmt)
{
printf("%3d:", stmt->lineno);
switch (stmt->cmd_type)
@@ -584,7 +584,7 @@ dump_stmt(PLpgSQL_stmt * stmt)
}
static void
dump_stmts(PLpgSQL_stmts * stmts)
dump_stmts(PLpgSQL_stmts *stmts)
{
int i;
@@ -595,7 +595,7 @@ dump_stmts(PLpgSQL_stmts * stmts)
}
static void
dump_block(PLpgSQL_stmt_block * block)
dump_block(PLpgSQL_stmt_block *block)
{
int i;
char *name;
@@ -635,7 +635,7 @@ dump_block(PLpgSQL_stmt_block * block)
}
static void
dump_assign(PLpgSQL_stmt_assign * stmt)
dump_assign(PLpgSQL_stmt_assign *stmt)
{
dump_ind();
printf("ASSIGN var %d := ", stmt->varno);
@@ -644,7 +644,7 @@ dump_assign(PLpgSQL_stmt_assign * stmt)
}
static void
dump_if(PLpgSQL_stmt_if * stmt)
dump_if(PLpgSQL_stmt_if *stmt)
{
dump_ind();
printf("IF ");
@@ -663,7 +663,7 @@ dump_if(PLpgSQL_stmt_if * stmt)
}
static void
dump_loop(PLpgSQL_stmt_loop * stmt)
dump_loop(PLpgSQL_stmt_loop *stmt)
{
dump_ind();
printf("LOOP\n");
@@ -675,7 +675,7 @@ dump_loop(PLpgSQL_stmt_loop * stmt)
}
static void
dump_while(PLpgSQL_stmt_while * stmt)
dump_while(PLpgSQL_stmt_while *stmt)
{
dump_ind();
printf("WHILE ");
@@ -689,7 +689,7 @@ dump_while(PLpgSQL_stmt_while * stmt)
}
static void
dump_fori(PLpgSQL_stmt_fori * stmt)
dump_fori(PLpgSQL_stmt_fori *stmt)
{
dump_ind();
printf("FORI %s %s\n", stmt->var->refname, (stmt->reverse) ? "REVERSE" : "NORMAL");
@@ -712,7 +712,7 @@ dump_fori(PLpgSQL_stmt_fori * stmt)
}
static void
dump_fors(PLpgSQL_stmt_fors * stmt)
dump_fors(PLpgSQL_stmt_fors *stmt)
{
dump_ind();
printf("FORS %s ", (stmt->rec != NULL) ? stmt->rec->refname : stmt->row->refname);
@@ -726,7 +726,7 @@ dump_fors(PLpgSQL_stmt_fors * stmt)
}
static void
dump_select(PLpgSQL_stmt_select * stmt)
dump_select(PLpgSQL_stmt_select *stmt)
{
dump_ind();
printf("SELECT ");
@@ -749,7 +749,7 @@ dump_select(PLpgSQL_stmt_select * stmt)
}
static void
dump_open(PLpgSQL_stmt_open * stmt)
dump_open(PLpgSQL_stmt_open *stmt)
{
dump_ind();
printf("OPEN curvar=%d\n", stmt->curvar);
@@ -781,7 +781,7 @@ dump_open(PLpgSQL_stmt_open * stmt)
}
static void
dump_fetch(PLpgSQL_stmt_fetch * stmt)
dump_fetch(PLpgSQL_stmt_fetch *stmt)
{
dump_ind();
printf("FETCH curvar=%d\n", stmt->curvar);
@@ -802,14 +802,14 @@ dump_fetch(PLpgSQL_stmt_fetch * stmt)
}
static void
dump_close(PLpgSQL_stmt_close * stmt)
dump_close(PLpgSQL_stmt_close *stmt)
{
dump_ind();
printf("CLOSE curvar=%d\n", stmt->curvar);
}
static void
dump_perform(PLpgSQL_stmt_perform * stmt)
dump_perform(PLpgSQL_stmt_perform *stmt)
{
dump_ind();
printf("PERFORM expr = ");
@@ -818,7 +818,7 @@ dump_perform(PLpgSQL_stmt_perform * stmt)
}
static void
dump_exit(PLpgSQL_stmt_exit * stmt)
dump_exit(PLpgSQL_stmt_exit *stmt)
{
dump_ind();
printf("EXIT lbl='%s'", stmt->label);
@@ -831,7 +831,7 @@ dump_exit(PLpgSQL_stmt_exit * stmt)
}
static void
dump_return(PLpgSQL_stmt_return * stmt)
dump_return(PLpgSQL_stmt_return *stmt)
{
dump_ind();
printf("RETURN ");
@@ -847,7 +847,7 @@ dump_return(PLpgSQL_stmt_return * stmt)
}
static void
dump_return_next(PLpgSQL_stmt_return_next * stmt)
dump_return_next(PLpgSQL_stmt_return_next *stmt)
{
dump_ind();
printf("RETURN NEXT ");
@@ -861,7 +861,7 @@ dump_return_next(PLpgSQL_stmt_return_next * stmt)
}
static void
dump_raise(PLpgSQL_stmt_raise * stmt)
dump_raise(PLpgSQL_stmt_raise *stmt)
{
int i;
@@ -873,7 +873,7 @@ dump_raise(PLpgSQL_stmt_raise * stmt)
}
static void
dump_execsql(PLpgSQL_stmt_execsql * stmt)
dump_execsql(PLpgSQL_stmt_execsql *stmt)
{
dump_ind();
printf("EXECSQL ");
@@ -882,7 +882,7 @@ dump_execsql(PLpgSQL_stmt_execsql * stmt)
}
static void
dump_dynexecute(PLpgSQL_stmt_dynexecute * stmt)
dump_dynexecute(PLpgSQL_stmt_dynexecute *stmt)
{
dump_ind();
printf("EXECUTE ");
@@ -891,7 +891,7 @@ dump_dynexecute(PLpgSQL_stmt_dynexecute * stmt)
}
static void
dump_dynfors(PLpgSQL_stmt_dynfors * stmt)
dump_dynfors(PLpgSQL_stmt_dynfors *stmt)
{
dump_ind();
printf("FORS %s EXECUTE ", (stmt->rec != NULL) ? stmt->rec->refname : stmt->row->refname);
@@ -905,7 +905,7 @@ dump_dynfors(PLpgSQL_stmt_dynfors * stmt)
}
static void
dump_getdiag(PLpgSQL_stmt_getdiag * stmt)
dump_getdiag(PLpgSQL_stmt_getdiag *stmt)
{
int i;
@@ -939,7 +939,7 @@ dump_getdiag(PLpgSQL_stmt_getdiag * stmt)
}
static void
dump_expr(PLpgSQL_expr * expr)
dump_expr(PLpgSQL_expr *expr)
{
int i;
@@ -959,7 +959,7 @@ dump_expr(PLpgSQL_expr * expr)
}
void
plpgsql_dumptree(PLpgSQL_function * func)
plpgsql_dumptree(PLpgSQL_function *func)
{
int i;
PLpgSQL_datum *d;

View File

@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plpgsql/src/plpgsql.h,v 1.52 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpgsql/src/plpgsql.h,v 1.53 2004/08/30 02:54:42 momjian Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
@@ -149,7 +149,7 @@ typedef struct
int alloc;
int used;
char *value;
} PLpgSQL_dstring;
} PLpgSQL_dstring;
typedef struct
@@ -163,7 +163,7 @@ typedef struct
Oid typioparam;
FmgrInfo typinput; /* lookup info for typinput function */
int32 atttypmod; /* typmod (taken from someplace else) */
} PLpgSQL_type;
} PLpgSQL_type;
/*
@@ -175,7 +175,7 @@ typedef struct
{ /* Generic datum array item */
int dtype;
int dno;
} PLpgSQL_datum;
} PLpgSQL_datum;
/*
* The variants PLpgSQL_var, PLpgSQL_row, and PLpgSQL_rec share these
@@ -187,7 +187,7 @@ typedef struct
int dno;
char *refname;
int lineno;
} PLpgSQL_variable;
} PLpgSQL_variable;
typedef struct PLpgSQL_expr
{ /* SQL Query to plan and execute */
@@ -205,7 +205,7 @@ typedef struct PLpgSQL_expr
/* params to pass to expr */
int nparams;
int params[1]; /* VARIABLE SIZE ARRAY ... must be last */
} PLpgSQL_expr;
} PLpgSQL_expr;
typedef struct
@@ -225,7 +225,7 @@ typedef struct
Datum value;
bool isnull;
bool freeval;
} PLpgSQL_var;
} PLpgSQL_var;
typedef struct
@@ -247,7 +247,7 @@ typedef struct
int nfields;
char **fieldnames;
int *varnos;
} PLpgSQL_row;
} PLpgSQL_row;
typedef struct
@@ -261,7 +261,7 @@ typedef struct
TupleDesc tupdesc;
bool freetup;
bool freetupdesc;
} PLpgSQL_rec;
} PLpgSQL_rec;
typedef struct
@@ -270,7 +270,7 @@ typedef struct
int rfno;
char *fieldname;
int recparentno; /* dno of parent record */
} PLpgSQL_recfield;
} PLpgSQL_recfield;
typedef struct
@@ -279,7 +279,7 @@ typedef struct
int dno;
PLpgSQL_expr *subscript;
int arrayparentno; /* dno of parent array variable */
} PLpgSQL_arrayelem;
} PLpgSQL_arrayelem;
typedef struct
@@ -287,7 +287,7 @@ typedef struct
int dtype;
int dno;
PLpgSQL_expr *argnum;
} PLpgSQL_trigarg;
} PLpgSQL_trigarg;
typedef struct
@@ -295,7 +295,7 @@ typedef struct
int itemtype;
int itemno;
char name[1];
} PLpgSQL_nsitem;
} PLpgSQL_nsitem;
typedef struct PLpgSQL_ns
@@ -304,14 +304,14 @@ typedef struct PLpgSQL_ns
int items_used;
PLpgSQL_nsitem **items;
struct PLpgSQL_ns *upper;
} PLpgSQL_ns;
} PLpgSQL_ns;
typedef struct
{ /* Generic execution node */
int cmd_type;
int lineno;
} PLpgSQL_stmt;
} PLpgSQL_stmt;
typedef struct
@@ -319,7 +319,7 @@ typedef struct
int stmts_alloc; /* XXX this oughta just be a List ... */
int stmts_used;
PLpgSQL_stmt **stmts;
} PLpgSQL_stmts;
} PLpgSQL_stmts;
typedef struct PLpgSQL_condition
@@ -327,14 +327,14 @@ typedef struct PLpgSQL_condition
int sqlerrstate; /* SQLSTATE code */
char *condname; /* condition name (for debugging) */
struct PLpgSQL_condition *next;
} PLpgSQL_condition;
} PLpgSQL_condition;
typedef struct
{ /* One EXCEPTION ... WHEN clause */
int lineno;
PLpgSQL_condition *conditions;
PLpgSQL_stmts *action;
} PLpgSQL_exception;
} PLpgSQL_exception;
typedef struct
@@ -343,7 +343,7 @@ typedef struct
* ... */
int exceptions_used;
PLpgSQL_exception **exceptions;
} PLpgSQL_exceptions;
} PLpgSQL_exceptions;
typedef struct
@@ -355,7 +355,7 @@ typedef struct
PLpgSQL_exceptions *exceptions;
int n_initvars;
int *initvarnos;
} PLpgSQL_stmt_block;
} PLpgSQL_stmt_block;
typedef struct
@@ -364,20 +364,20 @@ typedef struct
int lineno;
int varno;
PLpgSQL_expr *expr;
} PLpgSQL_stmt_assign;
} PLpgSQL_stmt_assign;
typedef struct
{ /* PERFORM statement */
int cmd_type;
int lineno;
PLpgSQL_expr *expr;
} PLpgSQL_stmt_perform;
} PLpgSQL_stmt_perform;
typedef struct
{ /* Get Diagnostics item */
int item; /* id for diagnostic value desired */
int target; /* where to assign it */
} PLpgSQL_diag_item;
} PLpgSQL_diag_item;
typedef struct
{ /* Get Diagnostics statement */
@@ -385,7 +385,7 @@ typedef struct
int lineno;
int ndtitems;
PLpgSQL_diag_item *dtitems;
} PLpgSQL_stmt_getdiag;
} PLpgSQL_stmt_getdiag;
typedef struct
@@ -395,7 +395,7 @@ typedef struct
PLpgSQL_expr *cond;
PLpgSQL_stmts *true_body;
PLpgSQL_stmts *false_body;
} PLpgSQL_stmt_if;
} PLpgSQL_stmt_if;
typedef struct
@@ -404,7 +404,7 @@ typedef struct
int lineno;
char *label;
PLpgSQL_stmts *body;
} PLpgSQL_stmt_loop;
} PLpgSQL_stmt_loop;
typedef struct
@@ -414,7 +414,7 @@ typedef struct
char *label;
PLpgSQL_expr *cond;
PLpgSQL_stmts *body;
} PLpgSQL_stmt_while;
} PLpgSQL_stmt_while;
typedef struct
@@ -427,7 +427,7 @@ typedef struct
PLpgSQL_expr *upper;
int reverse;
PLpgSQL_stmts *body;
} PLpgSQL_stmt_fori;
} PLpgSQL_stmt_fori;
typedef struct
@@ -439,7 +439,7 @@ typedef struct
PLpgSQL_row *row;
PLpgSQL_expr *query;
PLpgSQL_stmts *body;
} PLpgSQL_stmt_fors;
} PLpgSQL_stmt_fors;
typedef struct
@@ -451,7 +451,7 @@ typedef struct
PLpgSQL_row *row;
PLpgSQL_expr *query;
PLpgSQL_stmts *body;
} PLpgSQL_stmt_dynfors;
} PLpgSQL_stmt_dynfors;
typedef struct
@@ -461,7 +461,7 @@ typedef struct
PLpgSQL_rec *rec;
PLpgSQL_row *row;
PLpgSQL_expr *query;
} PLpgSQL_stmt_select;
} PLpgSQL_stmt_select;
typedef struct
@@ -473,7 +473,7 @@ typedef struct
PLpgSQL_expr *argquery;
PLpgSQL_expr *query;
PLpgSQL_expr *dynquery;
} PLpgSQL_stmt_open;
} PLpgSQL_stmt_open;
typedef struct
@@ -483,7 +483,7 @@ typedef struct
PLpgSQL_rec *rec;
PLpgSQL_row *row;
int curvar;
} PLpgSQL_stmt_fetch;
} PLpgSQL_stmt_fetch;
typedef struct
@@ -491,7 +491,7 @@ typedef struct
int cmd_type;
int lineno;
int curvar;
} PLpgSQL_stmt_close;
} PLpgSQL_stmt_close;
typedef struct
@@ -500,7 +500,7 @@ typedef struct
int lineno;
char *label;
PLpgSQL_expr *cond;
} PLpgSQL_stmt_exit;
} PLpgSQL_stmt_exit;
typedef struct
@@ -510,7 +510,7 @@ typedef struct
PLpgSQL_expr *expr;
int retrecno;
int retrowno;
} PLpgSQL_stmt_return;
} PLpgSQL_stmt_return;
typedef struct
{ /* RETURN NEXT statement */
@@ -519,7 +519,7 @@ typedef struct
PLpgSQL_rec *rec;
PLpgSQL_row *row;
PLpgSQL_expr *expr;
} PLpgSQL_stmt_return_next;
} PLpgSQL_stmt_return_next;
typedef struct
{ /* RAISE statement */
@@ -529,7 +529,7 @@ typedef struct
char *message;
int nparams;
int *params;
} PLpgSQL_stmt_raise;
} PLpgSQL_stmt_raise;
typedef struct
@@ -537,7 +537,7 @@ typedef struct
int cmd_type;
int lineno;
PLpgSQL_expr *sqlstmt;
} PLpgSQL_stmt_execsql;
} PLpgSQL_stmt_execsql;
typedef struct
@@ -545,7 +545,7 @@ typedef struct
int cmd_type;
int lineno;
PLpgSQL_expr *query;
} PLpgSQL_stmt_dynexecute;
} PLpgSQL_stmt_dynexecute;
typedef struct PLpgSQL_func_hashkey
@@ -566,7 +566,7 @@ typedef struct PLpgSQL_func_hashkey
* zeroed!
*/
Oid argtypes[FUNC_MAX_ARGS];
} PLpgSQL_func_hashkey;
} PLpgSQL_func_hashkey;
typedef struct PLpgSQL_function
@@ -602,7 +602,7 @@ typedef struct PLpgSQL_function
int ndatums;
PLpgSQL_datum **datums;
PLpgSQL_stmt_block *action;
} PLpgSQL_function;
} PLpgSQL_function;
typedef struct
@@ -639,7 +639,7 @@ typedef struct
PLpgSQL_function *err_func; /* current func */
PLpgSQL_stmt *err_stmt; /* current stmt */
const char *err_text; /* additional state info */
} PLpgSQL_execstate;
} PLpgSQL_execstate;
/**********************************************************************
@@ -682,10 +682,10 @@ extern int plpgsql_parse_dblwordrowtype(char *word);
extern PLpgSQL_type *plpgsql_parse_datatype(const char *string);
extern PLpgSQL_type *plpgsql_build_datatype(Oid typeOid, int32 typmod);
extern PLpgSQL_variable *plpgsql_build_variable(char *refname, int lineno,
PLpgSQL_type * dtype,
PLpgSQL_type *dtype,
bool add2namespace);
extern PLpgSQL_condition *plpgsql_parse_err_condition(char *condname);
extern void plpgsql_adddatum(PLpgSQL_datum * new);
extern void plpgsql_adddatum(PLpgSQL_datum *new);
extern int plpgsql_add_initdatums(int **varnos);
extern void plpgsql_HashTableInit(void);
@@ -701,9 +701,9 @@ extern Datum plpgsql_validator(PG_FUNCTION_ARGS);
* Functions in pl_exec.c
* ----------
*/
extern Datum plpgsql_exec_function(PLpgSQL_function * func,
extern Datum plpgsql_exec_function(PLpgSQL_function *func,
FunctionCallInfo fcinfo);
extern HeapTuple plpgsql_exec_trigger(PLpgSQL_function * func,
extern HeapTuple plpgsql_exec_trigger(PLpgSQL_function *func,
TriggerData *trigdata);
extern void plpgsql_xact_cb(XactEvent event, TransactionId parentXid, void *arg);
@@ -711,10 +711,10 @@ extern void plpgsql_xact_cb(XactEvent event, TransactionId parentXid, void *arg)
* Functions for the dynamic string handling in pl_funcs.c
* ----------
*/
extern void plpgsql_dstring_init(PLpgSQL_dstring * ds);
extern void plpgsql_dstring_free(PLpgSQL_dstring * ds);
extern void plpgsql_dstring_append(PLpgSQL_dstring * ds, char *str);
extern char *plpgsql_dstring_get(PLpgSQL_dstring * ds);
extern void plpgsql_dstring_init(PLpgSQL_dstring *ds);
extern void plpgsql_dstring_free(PLpgSQL_dstring *ds);
extern void plpgsql_dstring_append(PLpgSQL_dstring *ds, char *str);
extern char *plpgsql_dstring_get(PLpgSQL_dstring *ds);
/* ----------
* Functions for the namestack handling in pl_funcs.c
@@ -733,8 +733,8 @@ extern void plpgsql_ns_rename(char *oldname, char *newname);
* ----------
*/
extern void plpgsql_convert_ident(const char *s, char **output, int numidents);
extern const char *plpgsql_stmt_typename(PLpgSQL_stmt * stmt);
extern void plpgsql_dumptree(PLpgSQL_function * func);
extern const char *plpgsql_stmt_typename(PLpgSQL_stmt *stmt);
extern void plpgsql_dumptree(PLpgSQL_function *func);
/* ----------
* Externs in gram.y and scan.l

View File

@@ -29,7 +29,7 @@
* MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.54 2004/08/29 05:07:01 momjian Exp $
* $PostgreSQL: pgsql/src/pl/plpython/plpython.c,v 1.55 2004/08/30 02:54:42 momjian Exp $
*
*********************************************************************
*/
@@ -2114,7 +2114,7 @@ PLy_spi_execute_query(char *query, int limit)
oldcontext = CurrentMemoryContext;
PG_TRY();
rv = SPI_exec(query, limit);
rv = SPI_exec(query, limit);
PG_CATCH();
{
MemoryContextSwitchTo(oldcontext);
@@ -2375,7 +2375,7 @@ PLy_output(volatile int level, PyObject * self, PyObject * args)
oldcontext = CurrentMemoryContext;
PG_TRY();
elog(level, "%s", sv);
elog(level, "%s", sv);
PG_CATCH();
{
MemoryContextSwitchTo(oldcontext);

View File

@@ -31,7 +31,7 @@
* ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/pl/tcl/pltcl.c,v 1.90 2004/08/29 05:07:02 momjian Exp $
* $PostgreSQL: pgsql/src/pl/tcl/pltcl.c,v 1.91 2004/08/30 02:54:42 momjian Exp $
*
**********************************************************************/
@@ -109,7 +109,7 @@ typedef struct pltcl_proc_desc
FmgrInfo arg_out_func[FUNC_MAX_ARGS];
Oid arg_typioparam[FUNC_MAX_ARGS];
bool arg_is_rowtype[FUNC_MAX_ARGS];
} pltcl_proc_desc;
} pltcl_proc_desc;
/**********************************************************************
@@ -123,7 +123,7 @@ typedef struct pltcl_query_desc
Oid *argtypes;
FmgrInfo *arginfuncs;
Oid *argtypioparams;
} pltcl_query_desc;
} pltcl_query_desc;
/**********************************************************************
@@ -156,9 +156,9 @@ static ErrorData *pltcl_error_in_progress = NULL;
* Forward declarations
**********************************************************************/
static void pltcl_init_all(void);
static void pltcl_init_interp(Tcl_Interp * interp);
static void pltcl_init_interp(Tcl_Interp *interp);
static void pltcl_init_load_unknown(Tcl_Interp * interp);
static void pltcl_init_load_unknown(Tcl_Interp *interp);
Datum pltcl_call_handler(PG_FUNCTION_ARGS);
Datum pltclu_call_handler(PG_FUNCTION_ARGS);
@@ -170,28 +170,28 @@ static HeapTuple pltcl_trigger_handler(PG_FUNCTION_ARGS);
static pltcl_proc_desc *compile_pltcl_function(Oid fn_oid, Oid tgreloid);
static int pltcl_elog(ClientData cdata, Tcl_Interp * interp,
static int pltcl_elog(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_quote(ClientData cdata, Tcl_Interp * interp,
static int pltcl_quote(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_argisnull(ClientData cdata, Tcl_Interp * interp,
static int pltcl_argisnull(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_returnnull(ClientData cdata, Tcl_Interp * interp,
static int pltcl_returnnull(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_SPI_exec(ClientData cdata, Tcl_Interp * interp,
static int pltcl_SPI_exec(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_SPI_prepare(ClientData cdata, Tcl_Interp * interp,
static int pltcl_SPI_prepare(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_SPI_execp(ClientData cdata, Tcl_Interp * interp,
static int pltcl_SPI_execp(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static int pltcl_SPI_lastoid(ClientData cdata, Tcl_Interp * interp,
static int pltcl_SPI_lastoid(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[]);
static void pltcl_set_tuple_values(Tcl_Interp * interp, CONST84 char *arrayname,
static void pltcl_set_tuple_values(Tcl_Interp *interp, CONST84 char *arrayname,
int tupno, HeapTuple tuple, TupleDesc tupdesc);
static void pltcl_build_tuple_argument(HeapTuple tuple, TupleDesc tupdesc,
Tcl_DString * retval);
Tcl_DString *retval);
/*
@@ -292,7 +292,7 @@ pltcl_init_all(void)
* pltcl_init_interp() - initialize a Tcl interpreter
**********************************************************************/
static void
pltcl_init_interp(Tcl_Interp * interp)
pltcl_init_interp(Tcl_Interp *interp)
{
/************************************************************
* Install the commands for SPI support in the interpreter
@@ -322,7 +322,7 @@ pltcl_init_interp(Tcl_Interp * interp)
* table pltcl_modules (if it exists)
**********************************************************************/
static void
pltcl_init_load_unknown(Tcl_Interp * interp)
pltcl_init_load_unknown(Tcl_Interp *interp)
{
int spi_rc;
int tcl_rc;
@@ -1267,7 +1267,7 @@ compile_pltcl_function(Oid fn_oid, Oid tgreloid)
* pltcl_elog() - elog() support for PLTcl
**********************************************************************/
static int
pltcl_elog(ClientData cdata, Tcl_Interp * interp,
pltcl_elog(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
volatile int level;
@@ -1339,7 +1339,7 @@ pltcl_elog(ClientData cdata, Tcl_Interp * interp,
* be used in SPI_exec query strings
**********************************************************************/
static int
pltcl_quote(ClientData cdata, Tcl_Interp * interp,
pltcl_quote(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
char *tmp;
@@ -1392,7 +1392,7 @@ pltcl_quote(ClientData cdata, Tcl_Interp * interp,
* pltcl_argisnull() - determine if a specific argument is NULL
**********************************************************************/
static int
pltcl_argisnull(ClientData cdata, Tcl_Interp * interp,
pltcl_argisnull(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
int argno;
@@ -1449,7 +1449,7 @@ pltcl_argisnull(ClientData cdata, Tcl_Interp * interp,
* pltcl_returnnull() - Cause a NULL return from a function
**********************************************************************/
static int
pltcl_returnnull(ClientData cdata, Tcl_Interp * interp,
pltcl_returnnull(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
FunctionCallInfo fcinfo = pltcl_current_fcinfo;
@@ -1488,7 +1488,7 @@ pltcl_returnnull(ClientData cdata, Tcl_Interp * interp,
* for the Tcl interpreter
**********************************************************************/
static int
pltcl_SPI_exec(ClientData cdata, Tcl_Interp * interp,
pltcl_SPI_exec(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
volatile int my_rc;
@@ -1696,7 +1696,7 @@ pltcl_SPI_exec(ClientData cdata, Tcl_Interp * interp,
* and not save the plan currently.
**********************************************************************/
static int
pltcl_SPI_prepare(ClientData cdata, Tcl_Interp * interp,
pltcl_SPI_prepare(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
int nargs;
@@ -1843,7 +1843,7 @@ pltcl_SPI_prepare(ClientData cdata, Tcl_Interp * interp,
* pltcl_SPI_execp() - Execute a prepared plan
**********************************************************************/
static int
pltcl_SPI_execp(ClientData cdata, Tcl_Interp * interp,
pltcl_SPI_execp(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
volatile int my_rc;
@@ -2046,7 +2046,7 @@ pltcl_SPI_execp(ClientData cdata, Tcl_Interp * interp,
************************************************************/
oldcontext = CurrentMemoryContext;
PG_TRY();
spi_rc = SPI_execp(qdesc->plan, argvalues, nulls, count);
spi_rc = SPI_execp(qdesc->plan, argvalues, nulls, count);
PG_CATCH();
{
MemoryContextSwitchTo(oldcontext);
@@ -2168,7 +2168,7 @@ pltcl_SPI_execp(ClientData cdata, Tcl_Interp * interp,
* be used after insert queries
**********************************************************************/
static int
pltcl_SPI_lastoid(ClientData cdata, Tcl_Interp * interp,
pltcl_SPI_lastoid(ClientData cdata, Tcl_Interp *interp,
int argc, CONST84 char *argv[])
{
char buf[64];
@@ -2184,7 +2184,7 @@ pltcl_SPI_lastoid(ClientData cdata, Tcl_Interp * interp,
* of a given tuple
**********************************************************************/
static void
pltcl_set_tuple_values(Tcl_Interp * interp, CONST84 char *arrayname,
pltcl_set_tuple_values(Tcl_Interp *interp, CONST84 char *arrayname,
int tupno, HeapTuple tuple, TupleDesc tupdesc)
{
int i;
@@ -2281,7 +2281,7 @@ pltcl_set_tuple_values(Tcl_Interp * interp, CONST84 char *arrayname,
**********************************************************************/
static void
pltcl_build_tuple_argument(HeapTuple tuple, TupleDesc tupdesc,
Tcl_DString * retval)
Tcl_DString *retval)
{
int i;
char *outputstr;