Path: utzoo!attcan!uunet!lll-winken!lll-tis!ames!claris!apple!dan From: dan@Apple.COM (Dan Allen) Newsgroups: comp.sys.mac.programmer Subject: Re: Toolmaker's tip for MPW. Keywords: Link with stubs. Message-ID: <11094@apple.Apple.Com> Date: 27 May 88 01:47:27 GMT References: <8559@dartvax.Dartmouth.EDU> Reply-To: dan@apple.UUCP (Dan Allen) Organization: Apple Computer Inc, Cupertino, CA Lines: 20 Watch out for one GOTCHA, however. The stubs file as it ships with MPW also stubs out the routines that print floating point numbers. If you do a printf with a floating point number nothing will complain but your answer will be entirely wrong! A typical misuse of this stubs file came for me when I wrote a simple tool that did no floating point. Then I wanted to time the benchmark with TickCount and print the result rounded to tenths of a second. The answers came out all wrong. WORKAROUND: delete the last two lines of the file which are: ecvt() {} fcvt() {} and then your printf of floating point numbers will work properly and you will still save a bunch of space. Dan Allen Software Explorer Apple Computer