/[eiffelstudio]/branches/eth/eve/Src/Eiffel/API/evaluated_type/none_a.e
ViewVC logotype

Annotation of /branches/eth/eve/Src/Eiffel/API/evaluated_type/none_a.e

Parent Directory Parent Directory | Revision Log Revision Log


Revision 27398 - (hide annotations)
Thu Sep 6 01:22:17 2001 UTC (18 years, 4 months ago) by manus
Original Path: trunk/Src/bench/Eiffel/API/evaluated_type/none_a.e
File size: 1681 byte(s)
Fixed indexing clause with wrong description.

1 dinov 3375 indexing
2 manus 27398 description: "Actual type for NONE."
3 manus 9656 date: "$Date$"
4 manus 27398 revision: "$Revision$"
5 dinov 3375
6 manus 9656 class
7     NONE_A
8 grator 18
9     inherit
10 manus 9656 TYPE_A
11 grator 18 redefine
12 manus 9656 is_none, dump, type_i, same_as,
13 manus 26913 internal_conform_to
14 grator 18 end
15    
16 manus 9656 feature -- Comparison
17    
18     is_equivalent (other: like Current): BOOLEAN is
19     -- Is `other' equivalent to the current object ?
20     do
21     Result := True
22     end
23    
24 dinov 3078 feature -- Properties
25 grator 18
26 manus 9656 is_none: BOOLEAN is True
27 grator 18 -- Is the current type a none type ?
28    
29 dinov 3180 feature -- Access
30    
31     same_as (other: TYPE_A): BOOLEAN is
32     -- Is the current type the same as `other' ?
33     do
34 manus 9656 Result := other.is_none
35     end
36 dinov 3180
37 manus 11302 associated_class: CLASS_C is
38     do
39     -- No associated class
40     end
41    
42 dinov 3078 feature -- Output
43    
44 manus 9656 dump: STRING is "NONE"
45 grator 18 -- Dumped trace
46    
47 manus 26913 ext_append_to (st: STRUCTURED_TEXT; f: E_FEATURE) is
48 grator 296 do
49 manus 26913 st.add (ti_None_class)
50 manus 9656 end
51 grator 296
52 dinov 3180 feature {COMPILER_EXPORTER}
53 dinov 3078
54 manus 9656 create_info: CREATE_TYPE is
55     -- Byte code information for entity type creation
56     do
57 manus 10818 !! Result
58 manus 9656 Result.set_type (type_i)
59     end
60    
61 grator 18 type_i: NONE_I is
62     -- Void C type
63     once
64 manus 11722 Result := None_c_type
65 manus 9656 end
66 grator 18
67 manus 9656 internal_conform_to (other: TYPE_A in_generics: BOOLEAN): BOOLEAN is
68 grator 18 -- Does `other' conform to Current ?
69     do
70 manus 11263 -- If `other' is a basic, a BIT or an expanded type, it is not
71     -- conform to NONE.
72     --| When doing the check for `is_basic', we also check that `other'
73     --| can be a BIT type, so we do not need to add the check `other.is_bits'.
74 manus 11811 -- FIXME: This test needs to be done, but since it's causing to much trouble for now
75     -- we just desactivated it and we are back to the previous implementation
76     -- Result := not (other.is_basic or else other.is_expanded)
77 manus 26913 Result := not other.is_void
78 manus 9656 end
79 grator 18
80 dinov 3375 end -- class NONE_A

Properties

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

  ViewVC Help
Powered by ViewVC 1.1.23