🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: mod.computers.gould
Article #9

LIBPC TRUNC.c

#9
From: klimbal
Date: Fri, 22 Nov 1985 17:49
17 lines
925 bytes
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
Technical Details
Message-ID: <8511221749.AA10833@ei.Purdue.EDU>
Path: arc1-ca.pugleaf.net!utzoo!watmath!clyde!burl!ulysses!ucbvax!gouldbugs

Show Full Headers
Complete Article Headers
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: arc1-ca.pugleaf.net!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