+2014-07-16 Vadim Godunko <godunko@adacore.com>
+
+ * a-coinho.adb, a-coinho-shared.adb, a-coinho.ads, a-coinho-shared.ads:
+ Fix parameter mode of Update_Element.
+
2014-07-16 Robert Dewar <dewar@adacore.com>
* a-coinho.adb, a-coinho-shared.adb, a-coinho-shared.ads: Minor
begin
if Control.Container /= null then
Reference (Control.Container.Reference);
-
- declare
- B : Natural renames Control.Container.Busy;
- begin
- B := B + 1;
- end;
+ Control.Container.Busy := Control.Container.Busy + 1;
end if;
end Adjust;
if Control.Container /= null then
Unreference (Control.Container.Reference);
Control.Container.Busy := Control.Container.Busy - 1;
+ Control.Container := null;
end if;
-
- Control.Container := null;
end Finalize;
--------------
--------------------
procedure Update_Element
- (Container : Holder;
+ (Container : in out Holder;
Process : not null access procedure (Element : in out Element_Type))
is
- B : Natural renames Container'Unrestricted_Access.Busy;
+ B : Natural renames Container.Busy;
begin
if Container.Reference = null then
(Container : Holder;
Process : not null access procedure (Element : Element_Type));
procedure Update_Element
- (Container : Holder;
+ (Container : in out Holder;
Process : not null access procedure (Element : in out Element_Type));
type Constant_Reference_Type
--------------------
procedure Update_Element
- (Container : Holder;
+ (Container : in out Holder;
Process : not null access procedure (Element : in out Element_Type))
is
- B : Natural renames Container'Unrestricted_Access.Busy;
+ B : Natural renames Container.Busy;
begin
if Container.Element = null then
Process : not null access procedure (Element : Element_Type));
procedure Update_Element
- (Container : Holder;
+ (Container : in out Holder;
Process : not null access procedure (Element : in out Element_Type));
type Constant_Reference_Type