src/pl/tcl/pltcl.c
static int
pltcl_returnnull(ClientData cdata, Tcl_Interp *interp,
				 int objc, Tcl_Obj *const objv[])
{
	FunctionCallInfo fcinfo = pltcl_current_call_state->fcinfo;

	/************************************************************
	 * Check call syntax
	 ************************************************************/
	if (objc != 1)
	{
		Tcl_WrongNumArgs(interp, 1, objv, "");
		return TCL_ERROR;
	}

	/************************************************************
	 * Check that we're called as a normal function
	 ************************************************************/
	if (fcinfo == NULL)
	{
		Tcl_SetObjResult(interp,
						 Tcl_NewStringObj("return_null cannot be used in triggers", -1));
		return TCL_ERROR;
	}

	/************************************************************
	 * Set the NULL return flag and cause Tcl to return from the
	 * procedure.
	 ************************************************************/
	fcinfo->isnull = true;

	return TCL_RETURN;
}
/**********************************************************************
 * pltcl_returnnull()	- Cause a NULL return from the current function
 **********************************************************************/
pltcl_returnnull()   - Cause a NULL return from the current function
pltcl_returnnull () - Cause a NULL return from the current function
static int
pltcl_returnnull(ClientData cdata, Tcl_Interp *interp,
				 int objc, Tcl_Obj *const objv[])
{
	FunctionCallInfo fcinfo = pltcl_current_call_state->fcinfo;
	if (objc != 1)
	{
		Tcl_WrongNumArgs(interp, 1, objv, "");
		return TCL_ERROR;
	}
	if (fcinfo == NULL)
	{
		Tcl_SetObjResult(interp,
						 Tcl_NewStringObj("return_null cannot be used in triggers", -1));
		return TCL_ERROR;
	}
	fcinfo->isnull = true;
	return TCL_RETURN;
}
static int pltcl_returnnull ( ClientData cdata , Tcl_Interp * interp , int objc , Tcl_Obj * const objv [ ] ) { FunctionCallInfo fcinfo = pltcl_current_call_state -> fcinfo ; if ( objc != 1 ) { Tcl_WrongNumArgs ( interp , 1 , objv , " " ) ; return TCL_ERROR ; } if ( fcinfo == NULL ) { Tcl_SetObjResult ( interp , Tcl_NewStringObj ( " " , -1 ) ) ; return TCL_ERROR ; } fcinfo -> isnull = true ; return TCL_RETURN ; }
pltcl_returnnull()   - Cause a NULL return from the current function
pltcl_returnnull () - Cause a NULL return from the current function
/************************************************************
	 * Check call syntax
	 ************************************************************/ /************************************************************
	 * Check that we're called as a normal function
	 ************************************************************/ /************************************************************
	 * Set the NULL return flag and cause Tcl to return from the
	 * procedure.
	 ************************************************************/