cff4.c 611 B

12345678910111213141516171819202122232425262728
  1. /*
  2. (c) copyright 1988 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. /*
  7. CONVERT DOUBLE TO SINGLE (CFF 8 4)
  8. This routine works quite simply. A floating point
  9. of size 08 is converted to extended format.
  10. This extended variable is converted back to
  11. a floating point of size 04.
  12. */
  13. #include "FP_types.h"
  14. void
  15. cff4(src)
  16. DOUBLE src; /* the source itself - THIS TIME it's DOUBLE */
  17. {
  18. EXTEND buf;
  19. extend(&src.d[0],&buf,sizeof(DOUBLE)); /* no matter what */
  20. compact(&buf,&(src.d[1]),sizeof(SINGLE));
  21. }