home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!dtix!relay!relay2!afterlife!mssmith
- From: mssmith@afterlife.ncsc.mil (M. Scott Smith)
- Newsgroups: comp.sys.mac.programmer
- Subject: Re: Think Pascal->C conversion -- advice?
- Message-ID: <1992Dec19.155027.15141@afterlife.ncsc.mil>
- Date: 19 Dec 92 15:50:27 GMT
- References: <1992Dec18.021125.23146@afterlife.ncsc.mil> <1992Dec19.025507.22441@eng.umd.edu>
- Organization: The Great Beyond
- Lines: 27
-
- Hi.. Thanks for the information on converting, Ingemar and Matt.
-
- Ingemar: I agree with you, and think that Think C offers nominal speed
- increases over Think Pascal; I am not converting the code in the interest
- of speed, the Pascal version runs fast enough. There is a legitimate
- reason for converting the code to C, however. (Otherwise I wouldn't
- be wasting my time doing it!) Inevitably, this code is being designed
- to run on other platforms than the Mac, and this is just the first
- (necessary) step.
-
- I will be using prototypes.. I would rather be converting C from Pascal
- as well. In C you can easily accidentally write to all kinds of strange
- memory addresses, which are very hard to debug, while Pascal protects
- against that. I just have to be very careful.
-
- Matt: I like your idea for doing the 1-bit booleans, and I'll definitely
- give that a try. Unfortunately, it looks like I really have to be careful
- about this, because this program uses a LOT of packed arrays and a lot
- of memory; substituting 2-byte variables for 1-bit ones could very
- well break it; and this becomes more of a problem if the code is proted
- to machines that have 4-byte integers, etc.
-
- Thanks for your help! (Also thanks to a person who sent mail to me, of
- which I forget your name now.. But you offered good advice as well.)
-
- M. Scott Smith
- (mssmith@afterlife.ncsc.mil)
-