lace_physics_0.1.0_d1cb6621/source/physics-shape.adb

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
with
     ada.unchecked_Deallocation;

package body physics.Shape
is

   procedure free (Self : in out View)
   is
      procedure deallocate is new ada.unchecked_Deallocation (Item'Class, View);
   begin
      if Self /= null then
         Self.destruct;
      end if;

      deallocate (Self);
   end free;

end physics.Shape;