From 729d8db0971120c34509d36fc48d192529448447 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Thu, 16 Mar 2000 17:13:29 +0000 Subject: [PATCH] Add flonum operations FLO:<= FLO:>= FLO:MAX FLO:MIN. --- v7/src/runtime/fixart.scm | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/v7/src/runtime/fixart.scm b/v7/src/runtime/fixart.scm index 08c078033..7d172ca66 100644 --- a/v7/src/runtime/fixart.scm +++ b/v7/src/runtime/fixart.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: fixart.scm,v 1.4 1999/05/07 19:47:25 cph Exp $ +$Id: fixart.scm,v 1.5 2000/03/16 17:13:29 cph Exp $ -Copyright (c) 1988-1999 Massachusetts Institute of Technology +Copyright (c) 1988-2000 Massachusetts Institute of Technology This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -124,4 +124,16 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. (not (int:< x y))) (define-integrable (int:->flonum n) - ((ucode-primitive integer->flonum 2) n #b10)) \ No newline at end of file + ((ucode-primitive integer->flonum 2) n #b10)) + +(define-integrable (flo:<= x y) + (not (flo:> x y))) + +(define-integrable (flo:>= x y) + (not (flo:< x y))) + +(define (flo:min n m) + (if (flo:< n m) n m)) + +(define (flo:max n m) + (if (flo:> n m) n m)) \ No newline at end of file -- 2.25.1