Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site ucbvax.BERKELEY.EDU Path: utzoo!watmath!clyde!burl!ulysses!ucbvax!gouldbugs From: klimbal@EE.PURDUE.EDU Newsgroups: mod.computers.gould Subject: LIBPC TRUNC.c Message-ID: <8511221749.AA10833@ei.Purdue.EDU> Date: Fri, 22-Nov-85 12:49:25 EST Article-I.D.: ei.8511221749.AA10833 Posted: Fri Nov 22 12:49:25 1985 Date-Received: Mon, 25-Nov-85 07:38:01 EST Sender: daemon@ucbvax.BERKELEY.EDU Organization: The ARPA Internet Lines: 17 Approved: gouldbugs@brl.arpa In order for trunc to work correctly on the 9080 the return value must first be cast to a float and then to a long. /* Copyright (c) 1979 Regents of the University of California */ static char sccsid[] = "@(#)TRUNC.c 1.2 3/7/81"; long TRUNC(value) double value; { return (long)(float)(value); } --Phil