system.pp 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. {
  2. This file is part of the Free Pascal run time library.
  3. Copyright (c) 2006 by Florian Klaempfl
  4. member of the Free Pascal development team.
  5. System unit for embedded systems
  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 System;
  13. {*****************************************************************************}
  14. interface
  15. {*****************************************************************************}
  16. {$define FPC_IS_SYSTEM}
  17. {$I-,Q-,H-,R-,V-}
  18. {$mode objfpc}
  19. Type
  20. { The compiler has all integer types defined internally. Here
  21. we define only aliases }
  22. DWord = LongWord;
  23. Cardinal = LongWord;
  24. Integer = SmallInt;
  25. UInt64 = QWord;
  26. ValReal = Double;
  27. { map comp to int64, }
  28. Comp = Int64;
  29. HResult = type longint;
  30. { Java primitive types }
  31. jboolean = boolean;
  32. jbyte = shortint;
  33. jshort = smallint;
  34. jint = longint;
  35. jlong = int64;
  36. jchar = widechar;
  37. jfloat = single;
  38. jdouble = double;
  39. const
  40. { max. values for longint and int}
  41. maxLongint = $7fffffff;
  42. maxSmallint = 32767;
  43. maxint = maxsmallint;
  44. type
  45. { Java base class type }
  46. TObject = class external 'java.lang' name 'Object'
  47. protected
  48. function clone: TObject;
  49. public
  50. constructor create;
  51. function equals(obj: TObject): boolean;
  52. function hashcode: longint;
  53. end;
  54. {$i innr.inc}
  55. {$i jmathh.inc}
  56. {*****************************************************************************}
  57. implementation
  58. {*****************************************************************************}
  59. {*****************************************************************************
  60. Misc. System Dependent Functions
  61. *****************************************************************************}
  62. {*****************************************************************************
  63. SystemUnit Initialization
  64. *****************************************************************************}
  65. end.