sysutils.pp 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141
  1. {
  2. $Id$
  3. This file is part of the Free Pascal run time library.
  4. Copyright (c) 1998 by Florian Klaempfl
  5. member of the Free Pascal development team
  6. See the file COPYING.FPC, included in this distribution,
  7. for details about the copyright.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  11. **********************************************************************}
  12. unit sysutils;
  13. interface
  14. uses dos,objpas; { should become platform independent }
  15. type
  16. { some helpful data types }
  17. tprocedure = procedure;
  18. tfilename = string;
  19. longrec = packed record
  20. lo,hi : word;
  21. end;
  22. wordrec = packed record
  23. lo,hi : byte;
  24. end;
  25. { exceptions }
  26. {$ifndef VER0_99_5}
  27. exception = class(tobject)
  28. private
  29. fmessage : string;
  30. fhelpcontext : longint;
  31. public
  32. constructor create(const msg : string);
  33. //!! No array of const yet.
  34. // constructor createfmt(const msg; const args : array of const);
  35. constructor createres(indent : longint);
  36. { !!!! }
  37. property helpcontext : longint read fhelpcontext write fhelpcontext;
  38. property message : string read fmessage write fmessage;
  39. end;
  40. exceptclass = class of exception;
  41. { math. exceptions }
  42. einterror = class(exception);
  43. edivbyzero = class(einterror);
  44. erangeerror = class(einterror);
  45. eintoverflow = class(einterror);
  46. ematherror = class(exception);
  47. {$endif}
  48. { Read date & Time function declarations }
  49. {$i datih.inc}
  50. { Read String Handling functions declaration }
  51. {$i sysstrh.inc}
  52. { Read pchar handling functions declration }
  53. {$i syspchh.inc}
  54. { Read filename handling functions declaration }
  55. {$i finah.inc}
  56. implementation
  57. { Read filename handling functions implementation }
  58. {$i fina.inc}
  59. { Read date & Time function implementations }
  60. {$i dati.inc}
  61. { Read String Handling functions implementation }
  62. {$i sysstr.inc}
  63. { Read pchar handling functions implementation }
  64. {$i syspch.inc}
  65. {$ifndef VER0_99_5}
  66. constructor exception.create(const msg : string);
  67. begin
  68. inherited create;
  69. message:=msg;
  70. {!!!!!}
  71. end;
  72. {
  73. constructor exception.createfmt(const msg; const args : array of const);
  74. begin
  75. inherited create;
  76. end;
  77. }
  78. constructor exception.createres(indent : longint);
  79. begin
  80. inherited create;
  81. {!!!!!}
  82. end;
  83. {$endif}
  84. end.
  85. {
  86. $Log$
  87. Revision 1.4 1998-08-10 15:52:27 peter
  88. * fixed so 0.99.5 compiles it, but no exception class
  89. Revision 1.3 1998/07/29 15:44:32 michael
  90. included sysutils and math.pp as target. They compile now.
  91. Revision 1.2 1998/04/10 15:18:21 michael
  92. Added a lot of functions donated by GertJan Schouten
  93. Revision 1.1.1.1 1998/03/25 11:18:49 root
  94. * Restored version
  95. Revision 1.1 1998/02/05 11:11:32 michael
  96. + moved to objpas directory
  97. Revision 1.2 1998/02/03 15:27:25 florian
  98. *** empty log message ***
  99. Revision 1.1 1998/02/01 23:32:01 florian
  100. + initial revision
  101. }