with System; package body Date_Conversion_Template is Result : Integer; function Convert_To_Date (M : in Month; D : in Day; Y : in Year; the_date : in System.Address) return Integer; function Split (The_Date : in Date; M : in System.Address; D : in System.Address; Y : in System.Address) return Integer; pragma INTERFACE (C, Convert_To_Date); pragma INTERFACE (C, Split); pragma INTERFACE_NAME (Convert_To_Date, "_convert_to_date"); pragma INTERFACE_NAME (Split, "_split"); function Convert_To_Date (Using_Month : in Month; Using_Day : in Day; Using_Year : in Year) return Date is The_Date : Date; begin Result := Convert_To_Date (Using_Month, Using_Day, Using_Year, The_Date'ADDRESS); if Result /= 0 then raise Date_Error; end if; return The_Date; end Convert_To_Date; procedure Split (The_Date : in Date; Into_Month : out Month; Into_Day : out Day; Into_Year : out Year) is begin Result := Split (The_Date, Into_Month'ADDRESS, Into_Day'ADDRESS, Into_Year'ADDRESS); if Result /= 0 then raise Date_Error; end if; end Split; end;