Xref: utzoo comp.lang.c++:11842 comp.lang.c:36487 Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!uunet!pilchuck!dataio!fnx!nazgul!bright From: bright@nazgul.UUCP (Walter Bright) Newsgroups: comp.lang.c++,comp.lang.c Subject: Re: TC++: "floating point formats not linked" Message-ID: <268@nazgul.UUCP> Date: 23 Feb 91 17:28:12 GMT References: <1991Feb9.193059.14322@ucselx.sdsu.edu> Reply-To: bright@nazgul.UUCP (Walter Bright) Organization: Zortech, Seattle Lines: 25 In article kirste@methan.chemie.fu-berlin.de (Burkhard Kirste) writes: />In TC++, running in "C" mode , the following code gives the error message: />"scanf: floating point formats not linked" />How do I link them? /> float *w /> fscanf(fp,"%f\n",w); /I have found that a statement such as / atof(""); /would help. Anyway, I think that this "feature" of TC is a nuisance. In TC, the floating point library is only linked in if one of the OBJ files for the program contained a floating point operation. This is nice because if you don't use floating point you don't carry around the bulk of the library code. The downside is this causes a significant burden on the tech support, as I have seen this one problem appearing over and over again for *years*. In ZTC, we use the opposite approach. Floating point is always linked in by default. If you don't need it, then compile with -mi or link in the INT.OBJ object module. The upside is we never get tech support calls like the one above. The downside is many people never notice the -mi switch and wind up thinking that ZTC generates unnaturally large EXE files. Even many magazine reviewers have fallen into this error. I'm all ears if anyone has a suggestion on how to get the best of both by default.