/[eiffelstudio]/trunk/Delivery/studio/built_ins/neutral/REAL_32.e
ViewVC logotype

Contents of /trunk/Delivery/studio/built_ins/neutral/REAL_32.e

Parent Directory Parent Directory | Revision Log Revision Log


Revision 82025 - (show annotations)
Thu Jan 7 17:55:49 2010 UTC (10 years ago) by manus
File size: 2706 byte(s)
Added `is_nan' support.

1 class REAL_32
2
3 feature -- Comparison
4
5 is_less alias "<" (other: REAL_32): BOOLEAN is
6 -- Is `other' greater than current real?
7 do
8 Result := Precursor (other)
9 end
10 infix "<" (other: REAL_32): BOOLEAN is
11 -- Is `other' greater than current real?
12 do
13 Result := Precursor (other)
14 end
15
16 feature -- Status report
17
18 is_nan: BOOLEAN
19 do
20 Result := Precursor
21 end
22
23 feature -- Conversion
24
25 truncated_to_integer: INTEGER_32 is
26 -- Integer part (same sign, largest absolute
27 -- value no greater than current object's)
28 do
29 Result := Precursor
30 end
31
32 truncated_to_integer_64: INTEGER_64 is
33 -- Integer part (same sign, largest absolute
34 -- value no greater than current object's)
35 do
36 Result := Precursor
37 end
38
39 to_double: REAL_64 is
40 -- Current seen as a double
41 do
42 Result := Precursor
43 end
44
45 ceiling_real_32: REAL_32 is
46 -- Smallest integral value no smaller than current object
47 do
48 Result := Precursor
49 end
50
51 floor_real_32: REAL_32 is
52 -- Greatest integral value no greater than current object
53 do
54 Result := Precursor
55 end
56
57 feature -- Basic operations
58
59 plus alias "+" (other: REAL_32): REAL_32 is
60 -- Sum with `other'
61 do
62 Result := Precursor (other)
63 end
64
65 minus alias "-" (other: REAL_32): REAL_32 is
66 -- Result of subtracting `other'
67 do
68 Result := Precursor (other)
69 end
70
71 product alias "*" (other: REAL_32): REAL_32 is
72 -- Product by `other'
73 do
74 Result := Precursor (other)
75 end
76
77 quotient alias "/" (other: REAL_32): REAL_32 is
78 -- Division by `other'
79 do
80 Result := Precursor (other)
81 end
82
83 power alias "^" (other: REAL_64): REAL_64 is
84 -- Current real to the power `other'
85 do
86 Result := Precursor (other)
87 end
88
89 identity alias "+": REAL_32 is
90 -- Unary plus
91 do
92 Result := Precursor
93 end
94
95 opposite alias "-": REAL_32 is
96 -- Unary minus
97 do
98 Result := Precursor
99 end
100
101 infix "+" (other: REAL_32): REAL_32 is
102 -- Sum with `other'
103 do
104 Result := Precursor (other)
105 end
106
107 infix "-" (other: REAL_32): REAL_32 is
108 -- Result of subtracting `other'
109 do
110 Result := Precursor (other)
111 end
112
113 infix "*" (other: REAL_32): REAL_32 is
114 -- Product by `other'
115 do
116 Result := Precursor (other)
117 end
118
119 infix "/" (other: REAL_32): REAL_32 is
120 -- Division by `other'
121 do
122 Result := Precursor (other)
123 end
124
125 infix "^" (other: REAL_64): REAL_64 is
126 -- Current real to the power `other'
127 do
128 Result := Precursor (other)
129 end
130
131 prefix "+": REAL_32 is
132 -- Unary plus
133 do
134 Result := Precursor
135 end
136
137 prefix "-": REAL_32 is
138 -- Unary minus
139 do
140 Result := Precursor
141 end
142
143 feature -- Output
144
145 out: STRING is
146 -- Printable representation of real value
147 do
148 Result := Precursor
149 end
150
151 end

Properties

Name Value
svn:eol-style native
svn:keywords Author Date ID Revision

  ViewVC Help
Powered by ViewVC 1.1.23