[net.lang.c] How to declare a pointer to function returning pointer to function

reg@vaxine.UUCP (Rick Genter) (08/27/85)

     I couldn't resist trying this.  Cdecl claims no problem declaring
something to be a pointer to a function returning a pointer to a function
returning int:

Script started on Tue Aug 27 09:27:43 1985

% cdecl
declare x as pointer to function returning pointer to function returning int
int (*(*x)())()
%

Script done on Tue Aug 27 09:28:32 1985

     No, that's not lisp ... :-)

                                        - reg
                                        Rick Genter
                                        Automatix Inc.
                                        ...!decvax!encore!vaxine!reg

(Note: As of next week (9/3/85) I will be at BBN Labs.  I don't know what my
       new electronic address will be).

chris@umcp-cs.UUCP (Chris Torek) (08/28/85)

> I couldn't resist trying this.  Cdecl claims no problem declaring
> something to be a pointer to a function returning a pointer to a
> function returning int:

There *is* no problem declaring that.  The problem is declaring a
function returning a pointer to a function returning a pointer to
a function returning a pointer to a ..., ad infinitum.  *There is
no base type in the definition*.
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 4251)
UUCP:	seismo!umcp-cs!chris
CSNet:	chris@umcp-cs		ARPA:	chris@maryland