--- a/ShortFloat.st Wed Nov 20 16:33:50 2019 +0100
+++ b/ShortFloat.st Wed Nov 20 16:34:11 2019 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 1996 by Claus Gittinger
All Rights Reserved
@@ -16,7 +18,7 @@
LimitedPrecisionReal variableByteSubclass:#ShortFloat
instanceVariableNames:''
classVariableNames:'DefaultPrintFormat DefaultPrintfFormat Pi E Epsilon Ln10 NaN
- PositiveInfinity NegativeInfinity'
+ PositiveInfinity NegativeInfinity Phi'
poolDictionaries:''
category:'Magnitude-Numbers'
!
@@ -342,7 +344,6 @@
DefaultPrintFormat := aString.
! !
-
!ShortFloat class methodsFor:'binary storage'!
readBinaryIEEESingleFrom:aStream
@@ -558,6 +559,15 @@
"Modified (comment): / 09-06-2019 / 12:57:11 / Claus Gittinger"
!
+phi
+ "return the constant phi as ShortFloat"
+
+ Phi isNil ifTrue:[
+ Phi := Float phi asShortFloat
+ ].
+ ^ Phi
+!
+
pi
"return the constant pi as ShortFloat"
@@ -583,7 +593,6 @@
"Modified: 23.4.1996 / 09:26:45 / cg"
! !
-
!ShortFloat class methodsFor:'queries'!
defaultPrintPrecision