global Dir_Trailer

procedure Init_Separator ()
   if find("UNIX", &features) then {
      Dir_Trailer := "/"
   }
   else if find("MS-DOS" | "MS Windows NT", &features) then {
      Dir_Trailer := "\\"
   }
   else stop("Init_Separator: OS not supported")
end

procedure main ()
   local f, fname, check
   Init_Separator ()
   f := open (fname := ".oootest" || Dir_Trailer || "Boolean_X_Test.adb", "w") | stop ("Can't open " || fname)
   write (f, "-- Test file generated automatically by gentest.icn")
   write (f, "-- All your changes to this file might be discarded")
   write (f)
   write (f, "with Interfaces, Turbo, Ada.Text_IO;")
   write (f)
   write (f, "use  Interfaces, Turbo, Ada.Text_IO;")
   write (f)
   write (f, "procedure Boolean_X_Test is")
   write (f)
   write (f, "   Some_False_32     : Boolean_32 := +0;")
   write (f, "   Some_True_32      : Boolean_32 := +1;")
   write (f, "   Some_Also_True_32 : Boolean_32 := +(-2);")
   write (f, "   Some_False_8      : Boolean_8 := +0;")
   write (f, "   Some_True_8       : Boolean_8 := +1;")
   write (f, "   Some_Also_True_8  : Boolean_8 := +(-2);")
   write (f)
   write (f, "begin")
   every
      write (f, "   if " || (check := Gen_Check ()) ||
      " then\n      Put (\x22.\x22);\n   else\n      Put_Line (\x22Check \x22\x22" ||
      check || "\x22\x22 failed\x22);\n   end if;\n")
#   write (f)
   write (f, "end Boolean_X_Test;")
   close (f)
end