ShortFloat.st
changeset 11238 f321de80643a
parent 9896 307c7296064e
child 11720 79b29ccf5f3c
equal deleted inserted replaced
11237:ba77199427ce 11238:f321de80643a
     7  inclusion of the above copyright notice.   This software may not
     7  inclusion of the above copyright notice.   This software may not
     8  be provided or otherwise made available to, or used by, any
     8  be provided or otherwise made available to, or used by, any
     9  other person.  No title to or ownership of the software is
     9  other person.  No title to or ownership of the software is
    10  hereby transferred.
    10  hereby transferred.
    11 "
    11 "
    12 
       
    13 
       
    14 
       
    15 "{ Package: 'stx:libbasic' }"
    12 "{ Package: 'stx:libbasic' }"
    16 
    13 
    17 LimitedPrecisionReal variableByteSubclass:#ShortFloat
    14 LimitedPrecisionReal variableByteSubclass:#ShortFloat
    18 	instanceVariableNames:''
    15 	instanceVariableNames:''
    19 	classVariableNames:''
    16 	classVariableNames:''
   700 ! !
   697 ! !
   701 
   698 
   702 !ShortFloat methodsFor:'coercing & converting'!
   699 !ShortFloat methodsFor:'coercing & converting'!
   703 
   700 
   704 asFloat
   701 asFloat
   705     "return a Float with same value as the receiver"
   702     "return a Float with same value as the receiver.
       
   703      Redefined for performance (machine can do it faster)"
   706 
   704 
   707 %{  /* NOCONTEXT */
   705 %{  /* NOCONTEXT */
   708 
   706 
   709     OBJ newFloat;
   707     OBJ newFloat;
   710     double dVal = (double)__shortFloatVal(self);
   708     double dVal = (double)__shortFloatVal(self);
  1636 ! !
  1634 ! !
  1637 
  1635 
  1638 !ShortFloat class methodsFor:'documentation'!
  1636 !ShortFloat class methodsFor:'documentation'!
  1639 
  1637 
  1640 version
  1638 version
  1641     ^ '$Header: /cvs/stx/stx/libbasic/ShortFloat.st,v 1.95 2006-09-14 19:26:56 stefan Exp $'
  1639     ^ '$Header: /cvs/stx/stx/libbasic/ShortFloat.st,v 1.96 2008-10-19 21:25:02 cg Exp $'
  1642 ! !
  1640 ! !