home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / mac / system / 10292 < prev    next >
Encoding:
Text File  |  1992-07-22  |  1.3 KB  |  34 lines

  1. Newsgroups: comp.sys.mac.system
  2. Path: sparky!uunet!psinntp!python!raven!short
  3. From: short@microcom.com (Todd Short)
  4. Subject: Re: new Inside Mac : Pascal or C ?
  5. Message-ID: <1992Jul22.125412.20240@python.microcom.com>
  6. Sender: dan@python.microcom.com (Dan Bishop)
  7. Nntp-Posting-Host: raven
  8. Reply-To: short@microcom.com
  9. Organization: Microcom, Inc.
  10. References: <1992Jul21.162000.740@cnedcu51.bitnet>
  11. Date: Wed, 22 Jul 1992 12:54:12 GMT
  12. Lines: 20
  13.  
  14. In article 740@cnedcu51.bitnet, ifstadelmann@cnedcu51.bitnet (Patrick Stadelmann) writes:
  15. > Hi
  16. > Does anyone know if the new Inside Mac will be written in C or in Pascal ?
  17. >                    Thank you 
  18.  
  19. The problem of using both C and Pascal is the calling convention! C places the
  20. last argument on the stack first, Pascal puts the first argument on first. Also, 
  21. in C, the caller is supposed to clean up the stack, in Pascal, the callee does
  22. this. If you were able to use straight C in programming a Mac, then Apple would
  23. have to modify a lot of system calls. Windows uses the Pascal structure, and the
  24. "keyword" _pascal must be used in C to prototype it.  As in:
  25.  
  26.     extern far _pascal FunctionToBeCalled(...);
  27.  
  28. Do any Mac C programmer's know if this is true?
  29. ---
  30. -Todd Short
  31. /* short@python.eng.microcom.com */
  32. /* I don't own a Mac, but I'd like to buy one on TV */
  33.  
  34.