Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!swrinde!gem.mps.ohio-state.edu!brutus.cs.uiuc.edu!wuarchive!swbatl!uucibg From: uucibg@swbatl.UUCP (3929) Newsgroups: comp.sys.mac.programmer Subject: C++ interface to Object Pascal, whyfor? Keywords: C++, Object Pascal, interface, uses Message-ID: <934@swbatl.UUCP> Date: 13 Nov 89 02:36:43 GMT Organization: Southwestern Bell Tele. Co. - Advanced Technology Lab - St. Louis Lines: 47 I'm not trying to flame, I just want to make sure I understand the nature of the C++/Object-Pascal relationship. Please correct my misunderstandings: + Object Pascal uses objects a la Smalltalk (methods and dynamic dispatch). (Side note: does this mean that objects in Object Pascal are weakly typed?) + Apple has extended the Cfront translator so that you can work with Object Pascal style objects. + While it's possible (apparently) to mix-and-match Object Pascal Objects and C++ objects in the same program, trying to do so within a class or class heirarchy is going to have significant limitations (which are essentially unavoidable due to the differing semantics of "object" in the two languages). NOTE: I only said "apparently" above because I've not spent the time to figure out how to do it yet... :-) + It's not possible to involve Object Pascal classes in a multiple inheritance heirarchy. If this is correct, then it would seem that you can't use C++ to extend the Object Pascal heirarchies in a fashion that takes advantage of weak typing of objects (assuming that Object Pascal has weakly typed objects) or of the Multiple Inheritance of C++ (which would make sense given the nature of the dynamic-dispatch problem for mult. inheritance). This would seem to indicate that the interfaces are primarily for providing access to the power of MacApp. This is certainly a worthwhile objective and is valuable in and of itself. However, I'm wondering: what other advantages might this interface provide? DISCLAIMER: I wouldn't be at all surprised if much of the above is totally off kilter :-) Thanks, -------------------------------------------------------------------------------- Brian R. Gilstrap ...!{ texbell, uunet }!swbatl!uucibg OR uucibg@swbatl.UUCP One Bell Center +---------------------------------------------------------- Rm 17-G-4 | "Winnie-the-Pooh read the two notices very carefully, St. Louis, MO 63101 | first from left to right, and afterwards, in case he had (314) 235-3929 | missed some of it, from right to left." -- A. A. Milne -------------------------------------------------------------------------------- Disclaimer: Me, speak for my company? You must be joking. I'm just speaking my mind.