Date: Thu, 12 Sep 1996 09:36:56 +0200 (IST) From: Eli Zaretskii To: Jeff Cc: djgpp AT delorie DOT com Subject: Re: function pointers In-Reply-To: <517hq2$hqp@news.ghgcorp.com> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On 11 Sep 1996, Jeff wrote: > I wish to create a variable, such that a function (with parameters) > can be assigned to it. > > For example, in TurboP7.0: > type > ProcPTRType=procedure(x,y : integer); /* Declare `procedure' to be a pointer to a function which gets two integers and returns nothing. */ void (*procedure)(int, int); /* Use it. */ procedure = my_proc; /* Call it. */ (*my_proc)(x, y); Actually, you may say just "my_proc(x, y)", but some compilers out there didn't hear about ANSI C standard which allows this (DJGPP *does* know about this).