home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / mac / programm / 12797 < prev    next >
Encoding:
Internet Message Format  |  1992-07-21  |  1.3 KB

  1. Path: sparky!uunet!stanford.edu!agate!delft.Berkeley.EDU!chick
  2. From: chick@delft.Berkeley.EDU (Steve Chick)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Think C 5 subroutine size limit
  5. Date: 21 Jul 1992 22:10:25 GMT
  6. Organization: University of California, Berkeley
  7. Lines: 25
  8. Message-ID: <14i20hINN1bu@agate.berkeley.edu>
  9. NNTP-Posting-Host: delft.berkeley.edu
  10.  
  11. I am using Think C 5, and am trying to port some
  12. C code which functions well on several UNIX systems
  13. to the Mac.  One of the subroutines is rather large
  14. (>1000 lines, lots of local variables).
  15.  
  16. When compiling, Think C 5 terminates partway through
  17. the source with an error like 'invalid expression' on
  18. a simple arithmetic expression which compiled without
  19. complaint on a unix machine.  Commenting this line made
  20. the compiler terminate on the next expression (which was
  21. equally well formed in terms of syntax).
  22.  
  23. My conclusion, there is a limit to the size of the 
  24. subroutine within Think C 5.  Is this limit the 32K
  25. hardware limit of the Mac? or is it some other limit?
  26. (I tried beefing up the memory allocated to Think C
  27. by the finder by a factor of 2).
  28.  
  29. Has anyone had a similar experience? know of any work-
  30. arounds so I won't have to rewrite the subroutine into
  31. several smaller subroutines (not a small task)?
  32.  
  33. Any help would be appreciated.
  34. Steve Chick
  35. chick@cimsim.berkeley.edu
  36.