ucmp.c 369 B

123456789101112131415161718192021
  1. /*
  2. (c) copyright 1989 by the Vrije Universiteit, Amsterdam, The Netherlands.
  3. See the copyright notice in the ACK home directory, in the file "Copyright".
  4. */
  5. /* $Id$ */
  6. #include "flt_misc.h"
  7. int
  8. ucmp(l1,l2)
  9. long l1,l2;
  10. {
  11. if (l1 == l2) return 0;
  12. if (l2 >= 0) {
  13. if (l1 > l2 || l1 < 0) return 1;
  14. return -1;
  15. }
  16. if (l1 >= 0 || l1 < l2) return -1;
  17. return 1;
  18. }