Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!uunet!virtech!cpcahil From: cpcahil@virtech.UUCP (Conor P. Cahill) Newsgroups: comp.lang.c Subject: Re: Function pointers.. help! Message-ID: <1277@virtech.UUCP> Date: 14 Oct 89 01:22:13 GMT References: <3005@ndsuvax.UUCP> Organization: Virtual Technologies Inc Lines: 30 In article <3005@ndsuvax.UUCP>, nebakke@ndsuvax.UUCP (Jeff Bakke) writes: > Now, to me, this seems alright, but to the Turbo c 2.0 compiler, it > says that a Storage class is required. Assuming that the code you compiled looked as follows: void (*border_proc)(); void Assign_border(void (*user_border)()){ border_proc = user_border; } You should have had no problems with a compiler that correctly handles the new ANSI formal parameter declarations. pcc on 386/ix doesn't handle it, but the fix was simple: void Assign_border(user_border) void (*user_border)(); { border_proc = user_border; } gcc correctly handles either case. -- +-----------------------------------------------------------------------+ | Conor P. Cahill uunet!virtech!cpcahil 703-430-9247 ! | Virtual Technologies Inc., P. O. Box 876, Sterling, VA 22170 | +-----------------------------------------------------------------------+