Path: utzoo!attcan!uunet!munnari!iand From: iand@munnari.oz (Ian Robert Dobson) Newsgroups: comp.sys.mac.programmer Subject: LightSpeed C returning a pascal structure Message-ID: <2583@munnari.oz> Date: 23 Nov 88 01:55:36 GMT Organization: Comp Sci, Melbourne Uni, Australia Lines: 16 I am writing a program which utilises the list manager and have run into problems using LightSpeed C (3.0). The toolbox routine: Function LLastClick (lHandle : ListHandle) : Cell; would logically translate to: pascal Cell LLastClick(ListHandle lHandle) However LSC doesn't seem to want to return a non-integral pascal data type, so the routine is defined in the #include file as returning a 'long'. Furthermore, the type conversion between a long and a point gives me a 'bad cast' error, even though they are the same size. Does anybody have a solution to obtaining the cell (point) without manually converting the types by splitting the long in C code. Ian R. Dobson University of Melbourne munnari.oz!iand