* ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.30 2000/11/20 20:36:52 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/pl/tcl/pltcl.c,v 1.31 2000/12/08 00:09:07 tgl Exp $
*
**********************************************************************/
{
free(prodesc->proname);
free(prodesc);
- elog(ERROR, "pltcl: cache lookup for return type %u failed",
- procStruct->prorettype);
+ if (!OidIsValid(procStruct->prorettype))
+ elog(ERROR, "pltcl functions cannot return type \"opaque\""
+ "\n\texcept when used as triggers");
+ else
+ elog(ERROR, "pltcl: cache lookup for return type %u failed",
+ procStruct->prorettype);
}
typeStruct = (Form_pg_type) GETSTRUCT(typeTup);
{
free(prodesc->proname);
free(prodesc);
- elog(ERROR, "pltcl: cache lookup for argument type %u failed",
- procStruct->proargtypes[i]);
+ if (!OidIsValid(procStruct->proargtypes[i]))
+ elog(ERROR, "pltcl functions cannot take type \"opaque\"");
+ else
+ elog(ERROR, "pltcl: cache lookup for argument type %u failed",
+ procStruct->proargtypes[i]);
}
typeStruct = (Form_pg_type) GETSTRUCT(typeTup);