Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!uunet!mcsun!inria!imag!bordier From: bordier@imag.imag.fr (Jerome Bordier) Newsgroups: comp.sys.mac.programmer Subject: THINK C 4.0 anomaly ? Message-ID: <10979@imag.imag.fr> Date: 27 Jun 90 10:16:02 GMT Reply-To: bordier@imag.fr (Jerome Bordier) Organization: IMAG, University of Grenoble, France Lines: 33 Here is a piece of program which was well compiled with THINK C 3.0 : --- Boolean condition; pascal TPPrDlg MyJobDlgInit(hPrint) THPrint hPrint; { ... } Boolean My_PrJobDialog() { Boolean value; if (condition) value = PrDlgMain(print_record_hdle, &MyJobDlgInit); else value = PrDlgMain(print_record_hdle, &PrJobInit); return value; } --- I have added an #include to compile with THINK C 4.0 and the compiler refuse "&PrJobInit" (illegal "adress of" operator). N.B. PrJobInit is a function in the toolbox. There is a simple way to fix the problem in this particular case : replace the second call of PrDlgMain by "PrJobDialog(print_record_hdle);" which do the same thing (references :Printing Manager and Macintosh Technical Note #95). Nevertheless the problem seems to be an anomaly in the compiler. -- Jerome BORDIER Laboratoire de Structures Discretes et de Didactique IMAG B.P. 53 X 38041 GRENOBLE Cedex FRANCE TEL: (33) 76 51 45 53 FAX: (33) 76 51 45 55 INTERNET: bordier@imag.Fr UUCP: bordier@imag (uunet.uu.net!imag!bordier)