/[eiffelstudio]/branches/CAT_mono/Src/Eiffel/API/evaluated_type/gen_type_a.e
ViewVC logotype

Diff of /branches/CAT_mono/Src/Eiffel/API/evaluated_type/gen_type_a.e

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 69686 by manus, Mon Jul 23 21:36:18 2007 UTC revision 69687 by martins, Wed Jul 25 18:55:08 2007 UTC
# Line 53  feature -- Property Line 53  feature -- Property
53          generics: ARRAY [TYPE_A]          generics: ARRAY [TYPE_A]
54                          -- Actual generical parameter                          -- Actual generical parameter
55    
56            is_covariant (a_generic_position: INTEGER): BOOLEAN
57                            -- Is generic at `a_generic_position' marked as covariant?
58                    do
59                            if covariance_flags /= Void then
60                                    Result := covariance_flags [a_generic_position]
61                            end
62    
63                    end
64    
65  feature -- Comparison  feature -- Comparison
66    
67          is_equivalent (other: like Current): BOOLEAN is          is_equivalent (other: like Current): BOOLEAN is
# Line 240  feature {COMPILER_EXPORTER} -- Primitive Line 249  feature {COMPILER_EXPORTER} -- Primitive
249                          generics_set: generics = g                          generics_set: generics = g
250                  end                  end
251    
252            set_covariance_flags (a_flags: like covariance_flags) is
253                            -- Assign `a_flags' to `covariance_flags'.
254                    require
255                            a_flags_not_void: a_flags /= Void
256                    do
257                            covariance_flags := a_flags
258                    ensure
259                            covariance_flags_set: covariance_flags = a_flags
260                    end
261    
262          has_expanded: BOOLEAN is          has_expanded: BOOLEAN is
263                          -- Are some expanded type in the current generic declaration ?                          -- Are some expanded type in the current generic declaration ?
264                  local                  local
# Line 611  feature {COMPILER_EXPORTER} -- Primitive Line 630  feature {COMPILER_EXPORTER} -- Primitive
630                          end                          end
631                          Result := twin                          Result := twin
632                          Result.set_generics (duplicate_generics)                          Result.set_generics (duplicate_generics)
633                            if covariance_flags /= Void then
634                                    Result.set_covariance_flags (covariance_flags.twin)
635                            end
636                  end                  end
637    
638          good_generics: BOOLEAN is          good_generics: BOOLEAN is
# Line 1088  feature {COMPILER_EXPORTER} -- Primitive Line 1110  feature {COMPILER_EXPORTER} -- Primitive
1110                          end                          end
1111                  end                  end
1112    
1113    feature {NONE} -- Implementation
1114    
1115            covariance_flags: PACKED_BOOLEANS
1116                            -- Stores whether a generic at a certain position is marked covariant or not.
1117    
1118  invariant  invariant
1119    
1120                  -- A generic class always has generic parameters                  -- A generic class always has generic parameters

Legend:
Removed from v.69686  
changed lines
  Added in v.69687

  ViewVC Help
Powered by ViewVC 1.1.23