zemu 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (285) hide show
  1. checksums.yaml +7 -0
  2. data/lib/zemu/config.rb +312 -0
  3. data/lib/zemu/instance.rb +179 -0
  4. data/lib/zemu.rb +172 -0
  5. data/src/debug.c +118 -0
  6. data/src/debug.h +30 -0
  7. data/src/external/Z/API/Z/ABIs/generic/allocator.h +36 -0
  8. data/src/external/Z/API/Z/ABIs/generic/cipher.h +47 -0
  9. data/src/external/Z/API/Z/ABIs/generic/data codec.h +33 -0
  10. data/src/external/Z/API/Z/ABIs/generic/emulation.h +103 -0
  11. data/src/external/Z/API/Z/ABIs/generic/hash function.h +33 -0
  12. data/src/external/Z/API/Z/ABIs/generic/module.h +33 -0
  13. data/src/external/Z/API/Z/ABIs/generic/wave codec.h +40 -0
  14. data/src/external/Z/API/Z/classes/base/InitializerList.hpp +34 -0
  15. data/src/external/Z/API/Z/classes/base/OpaqueFunctionPointer.hpp +26 -0
  16. data/src/external/Z/API/Z/classes/base/OpaqueMemberFunctionPointer.hpp +26 -0
  17. data/src/external/Z/API/Z/classes/base/Pair.hpp +46 -0
  18. data/src/external/Z/API/Z/classes/base/Range.hpp +111 -0
  19. data/src/external/Z/API/Z/classes/base/SizedString.hpp +66 -0
  20. data/src/external/Z/API/Z/classes/base/Status.hpp +89 -0
  21. data/src/external/Z/API/Z/classes/base/Symbol.hpp +39 -0
  22. data/src/external/Z/API/Z/classes/base/Tuple.hpp +111 -0
  23. data/src/external/Z/API/Z/classes/base/Value2D.hpp +389 -0
  24. data/src/external/Z/API/Z/classes/base/Value3D.hpp +368 -0
  25. data/src/external/Z/API/Z/classes/buffering/RingBuffer.hpp +93 -0
  26. data/src/external/Z/API/Z/classes/buffering/TripleBuffer.hpp +68 -0
  27. data/src/external/Z/API/Z/classes/functional/Functor.hpp +265 -0
  28. data/src/external/Z/API/Z/classes/functional/MemberFunction.hpp +98 -0
  29. data/src/external/Z/API/Z/classes/functional/ObjectMemberFunction.hpp +172 -0
  30. data/src/external/Z/API/Z/classes/functional/ObjectSelector.hpp +219 -0
  31. data/src/external/Z/API/Z/classes/functional/Selector.hpp +146 -0
  32. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/AABB.hpp +81 -0
  33. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/AABR.hpp +685 -0
  34. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Box.hpp +219 -0
  35. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Circle.hpp +80 -0
  36. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Line2D.hpp +93 -0
  37. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Line3D.hpp +80 -0
  38. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Rectangle.hpp +675 -0
  39. data/src/external/Z/API/Z/classes/mathematics/geometry/euclidean/Sphere.hpp +0 -0
  40. data/src/external/Z/API/Z/classes/memory/Shared.hpp +90 -0
  41. data/src/external/Z/API/Z/constants/base.h +35 -0
  42. data/src/external/Z/API/Z/constants/chemical elements.h +6385 -0
  43. data/src/external/Z/API/Z/constants/numbers.h +963 -0
  44. data/src/external/Z/API/Z/constants/version.h +15 -0
  45. data/src/external/Z/API/Z/formats/character set/ASCII.h +158 -0
  46. data/src/external/Z/API/Z/formats/character set/DOS CP437.h +159 -0
  47. data/src/external/Z/API/Z/formats/character set/DOS CP737.h +159 -0
  48. data/src/external/Z/API/Z/formats/character set/DOS CP775.h +159 -0
  49. data/src/external/Z/API/Z/formats/character set/DOS CP850.h +159 -0
  50. data/src/external/Z/API/Z/formats/character set/DOS CP852.h +159 -0
  51. data/src/external/Z/API/Z/formats/character set/DOS CP855.h +159 -0
  52. data/src/external/Z/API/Z/formats/character set/DOS CP857.h +159 -0
  53. data/src/external/Z/API/Z/formats/character set/DOS CP858.h +159 -0
  54. data/src/external/Z/API/Z/formats/character set/DOS CP860.h +159 -0
  55. data/src/external/Z/API/Z/formats/character set/DOS CP861.h +159 -0
  56. data/src/external/Z/API/Z/formats/character set/DOS CP862.h +159 -0
  57. data/src/external/Z/API/Z/formats/character set/DOS CP863.h +159 -0
  58. data/src/external/Z/API/Z/formats/character set/DOS CP864.h +159 -0
  59. data/src/external/Z/API/Z/formats/character set/DOS CP865.h +159 -0
  60. data/src/external/Z/API/Z/formats/character set/DOS CP866.h +159 -0
  61. data/src/external/Z/API/Z/formats/character set/DOS CP869.h +159 -0
  62. data/src/external/Z/API/Z/formats/character set/DOS CP872.h +159 -0
  63. data/src/external/Z/API/Z/formats/character set/DOS CP874.h +159 -0
  64. data/src/external/Z/API/Z/formats/character set/Unicode.h +30119 -0
  65. data/src/external/Z/API/Z/formats/data model/I16LP32.h +19 -0
  66. data/src/external/Z/API/Z/formats/data model/ILP32.h +19 -0
  67. data/src/external/Z/API/Z/formats/data model/ILP64.h +19 -0
  68. data/src/external/Z/API/Z/formats/data model/IP16L32.h +19 -0
  69. data/src/external/Z/API/Z/formats/data model/LLP64.h +19 -0
  70. data/src/external/Z/API/Z/formats/data model/LP32.h +19 -0
  71. data/src/external/Z/API/Z/formats/data model/LP64.h +19 -0
  72. data/src/external/Z/API/Z/formats/data model/SILP64.h +19 -0
  73. data/src/external/Z/API/Z/formats/file system/FAT12.h +61 -0
  74. data/src/external/Z/API/Z/formats/floating-point/IEEE 754.h +141 -0
  75. data/src/external/Z/API/Z/formats/floating-point/x87.h +74 -0
  76. data/src/external/Z/API/Z/formats/image/ICNS.h +39 -0
  77. data/src/external/Z/API/Z/formats/keymap/Mac OS.h +284 -0
  78. data/src/external/Z/API/Z/formats/keymap/Z.h +141 -0
  79. data/src/external/Z/API/Z/formats/multimedia/Creative Voice.h +106 -0
  80. data/src/external/Z/API/Z/formats/multimedia/Microsoft Wave.h +49 -0
  81. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/ACH.h +44 -0
  82. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/FRZ.h +54 -0
  83. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/PRG.h +33 -0
  84. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/SEM.h +46 -0
  85. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/SIT.h +34 -0
  86. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/SNA.h +117 -0
  87. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/SNP.h +37 -0
  88. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/SP.h +62 -0
  89. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/Z80.h +117 -0
  90. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/ZX.h +56 -0
  91. data/src/external/Z/API/Z/formats/snapshot/machine/computer/ZX Spectrum/ZX82.h +70 -0
  92. data/src/external/Z/API/Z/formats/storage medium image/NES Game Pak/UNIF.h +26 -0
  93. data/src/external/Z/API/Z/formats/storage medium image/NES Game Pak/iNES.h +76 -0
  94. data/src/external/Z/API/Z/formats/storage medium image/audio/TAP.h +25 -0
  95. data/src/external/Z/API/Z/formats/storage medium image/audio/TZX.h +1185 -0
  96. data/src/external/Z/API/Z/formats/storage medium image/audio/Warajevo TAP.h +32 -0
  97. data/src/external/Z/API/Z/formats/storage medium image/floppy disk/FDI.h +45 -0
  98. data/src/external/Z/API/Z/functions/base/Z2D.h +583 -0
  99. data/src/external/Z/API/Z/functions/base/Z3D.h +712 -0
  100. data/src/external/Z/API/Z/functions/base/ZRange.h +137 -0
  101. data/src/external/Z/API/Z/functions/base/all.h +16 -0
  102. data/src/external/Z/API/Z/functions/base/casting.hpp +37 -0
  103. data/src/external/Z/API/Z/functions/base/character.h +38 -0
  104. data/src/external/Z/API/Z/functions/base/constructors.h +326 -0
  105. data/src/external/Z/API/Z/functions/base/structure.hpp +26 -0
  106. data/src/external/Z/API/Z/functions/base/type.hpp +60 -0
  107. data/src/external/Z/API/Z/functions/base/value.h +1901 -0
  108. data/src/external/Z/API/Z/functions/base/value.hpp +112 -0
  109. data/src/external/Z/API/Z/functions/buffering/ZRingBuffer.h +85 -0
  110. data/src/external/Z/API/Z/functions/buffering/ZTripleBuffer.h +65 -0
  111. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/Z2DLine.h +179 -0
  112. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/Z3DLine.h +168 -0
  113. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZAABB.h +361 -0
  114. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZAABR.h +1081 -0
  115. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZBox.h +340 -0
  116. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZCircle.h +142 -0
  117. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZRectangle.h +1267 -0
  118. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/ZSphere.h +156 -0
  119. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/all.h +18 -0
  120. data/src/external/Z/API/Z/functions/mathematics/geometry/euclidean/constructors.h +620 -0
  121. data/src/external/Z/API/Z/functions/time/date.h +29 -0
  122. data/src/external/Z/API/Z/hardware/CPU/architecture/6502.h +90 -0
  123. data/src/external/Z/API/Z/hardware/CPU/architecture/Z80.h +245 -0
  124. data/src/external/Z/API/Z/hardware/CPU/architecture/i4004.h +37 -0
  125. data/src/external/Z/API/Z/hardware/PSG/General Instrument/AY-3-891x.h +180 -0
  126. data/src/external/Z/API/Z/hardware/VDC/Ricoh/RP2C0x.h +625 -0
  127. data/src/external/Z/API/Z/hardware/bus/AGP.h +24 -0
  128. data/src/external/Z/API/Z/hardware/bus/USB.h +510 -0
  129. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/Inves Spectrum +.h +47 -0
  130. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/Pentagon.h +13 -0
  131. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/Scorpion.h +13 -0
  132. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum + 128K.h +158 -0
  133. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum +.h +82 -0
  134. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum +2.h +13 -0
  135. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum +2A.h +13 -0
  136. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum +3.h +13 -0
  137. data/src/external/Z/API/Z/hardware/machine/model/computer/ZX Spectrum/ZX Spectrum.h +109 -0
  138. data/src/external/Z/API/Z/hardware/machine/model/console/Nintendo Entertainment System/NES-001 (NTSC).h +29 -0
  139. data/src/external/Z/API/Z/hardware/machine/model/console/Nintendo Entertainment System/NES-001 (PAL).h +29 -0
  140. data/src/external/Z/API/Z/hardware/machine/platform/computer/ZX Spectrum.h +405 -0
  141. data/src/external/Z/API/Z/hardware/machine/platform/console/Game Boy.h +49 -0
  142. data/src/external/Z/API/Z/hardware/machine/platform/console/Nintendo Entertainment System.h +350 -0
  143. data/src/external/Z/API/Z/hardware/storage medium/ROM cartridge/SNES Game Pak.h +238 -0
  144. data/src/external/Z/API/Z/inspection/C/completion.h +178 -0
  145. data/src/external/Z/API/Z/inspection/C/modules/C11.h +41 -0
  146. data/src/external/Z/API/Z/inspection/C/modules/C18.h +13 -0
  147. data/src/external/Z/API/Z/inspection/C/modules/C89.h +19 -0
  148. data/src/external/Z/API/Z/inspection/C/modules/C90.h +13 -0
  149. data/src/external/Z/API/Z/inspection/C/modules/C94.h +15 -0
  150. data/src/external/Z/API/Z/inspection/C/modules/C99.h +29 -0
  151. data/src/external/Z/API/Z/inspection/C/modules/KR C.h +19 -0
  152. data/src/external/Z/API/Z/inspection/C++/completion.h +512 -0
  153. data/src/external/Z/API/Z/inspection/C++/modules/C++03.h +15 -0
  154. data/src/external/Z/API/Z/inspection/C++/modules/C++11.h +80 -0
  155. data/src/external/Z/API/Z/inspection/C++/modules/C++14.h +26 -0
  156. data/src/external/Z/API/Z/inspection/C++/modules/C++17.h +55 -0
  157. data/src/external/Z/API/Z/inspection/C++/modules/C++85.h +11 -0
  158. data/src/external/Z/API/Z/inspection/C++/modules/C++89.h +13 -0
  159. data/src/external/Z/API/Z/inspection/C++/modules/C++98.h +17 -0
  160. data/src/external/Z/API/Z/inspection/C++.h +78 -0
  161. data/src/external/Z/API/Z/inspection/C.h +79 -0
  162. data/src/external/Z/API/Z/inspection/CPU/completion.h +56 -0
  163. data/src/external/Z/API/Z/inspection/CPU/detection.h +714 -0
  164. data/src/external/Z/API/Z/inspection/CPU/modules/6502.h +25 -0
  165. data/src/external/Z/API/Z/inspection/CPU/modules/AArch32.h +32 -0
  166. data/src/external/Z/API/Z/inspection/CPU/modules/AArch64.h +32 -0
  167. data/src/external/Z/API/Z/inspection/CPU/modules/Z80.h +26 -0
  168. data/src/external/Z/API/Z/inspection/CPU/modules/x86-32.h +31 -0
  169. data/src/external/Z/API/Z/inspection/CPU/modules/x86-64.h +312 -0
  170. data/src/external/Z/API/Z/inspection/CPU.h +209 -0
  171. data/src/external/Z/API/Z/inspection/OS/completion.h +36 -0
  172. data/src/external/Z/API/Z/inspection/OS/detection.h +768 -0
  173. data/src/external/Z/API/Z/inspection/OS/modules/Linux.h +22 -0
  174. data/src/external/Z/API/Z/inspection/OS/modules/MS-DOS.h +16 -0
  175. data/src/external/Z/API/Z/inspection/OS/modules/Mac OS X.h +23 -0
  176. data/src/external/Z/API/Z/inspection/OS/modules/Windows.h +19 -0
  177. data/src/external/Z/API/Z/inspection/OS/modules/iPhone OS.h +23 -0
  178. data/src/external/Z/API/Z/inspection/OS.h +236 -0
  179. data/src/external/Z/API/Z/inspection/Objective-C/completion.h +8 -0
  180. data/src/external/Z/API/Z/inspection/Objective-C/modules/Objective-C v1.0.h +11 -0
  181. data/src/external/Z/API/Z/inspection/Objective-C/modules/Objective-C v2.0.h +15 -0
  182. data/src/external/Z/API/Z/inspection/Objective-C.h +51 -0
  183. data/src/external/Z/API/Z/inspection/Z.h +19 -0
  184. data/src/external/Z/API/Z/inspection/build.h +22 -0
  185. data/src/external/Z/API/Z/inspection/character set.h +66 -0
  186. data/src/external/Z/API/Z/inspection/compiler/completion.h +2885 -0
  187. data/src/external/Z/API/Z/inspection/compiler/modules/Apple LLVM.h +26 -0
  188. data/src/external/Z/API/Z/inspection/compiler/modules/Clang.h +1664 -0
  189. data/src/external/Z/API/Z/inspection/compiler/modules/GCC.h +1366 -0
  190. data/src/external/Z/API/Z/inspection/compiler/modules/SCCZ80.h +473 -0
  191. data/src/external/Z/API/Z/inspection/compiler/modules/Visual C++.h +606 -0
  192. data/src/external/Z/API/Z/inspection/compiler/modules/cc65.h +529 -0
  193. data/src/external/Z/API/Z/inspection/compiler/modules/generic.h +13 -0
  194. data/src/external/Z/API/Z/inspection/compiler/modules/template.h +650 -0
  195. data/src/external/Z/API/Z/inspection/compiler.h +299 -0
  196. data/src/external/Z/API/Z/inspection/data model/completion.h +128 -0
  197. data/src/external/Z/API/Z/inspection/data model/deduction.h +9 -0
  198. data/src/external/Z/API/Z/inspection/data model/detection.h +45 -0
  199. data/src/external/Z/API/Z/inspection/data model.h +362 -0
  200. data/src/external/Z/API/Z/inspection/floating-point/completion.h +50 -0
  201. data/src/external/Z/API/Z/inspection/floating-point.h +324 -0
  202. data/src/external/Z/API/Z/inspection/language.h +163 -0
  203. data/src/external/Z/API/Z/inspection/platform/detection.h +9 -0
  204. data/src/external/Z/API/Z/inspection/platform.h +29 -0
  205. data/src/external/Z/API/Z/keys/C++.h +27 -0
  206. data/src/external/Z/API/Z/keys/C.h +29 -0
  207. data/src/external/Z/API/Z/keys/CPU.h +80 -0
  208. data/src/external/Z/API/Z/keys/OS.h +182 -0
  209. data/src/external/Z/API/Z/keys/Objective-C.h +17 -0
  210. data/src/external/Z/API/Z/keys/chemistry.h +26 -0
  211. data/src/external/Z/API/Z/keys/compiler.h +178 -0
  212. data/src/external/Z/API/Z/keys/data model.h +32 -0
  213. data/src/external/Z/API/Z/keys/endianness.h +24 -0
  214. data/src/external/Z/API/Z/keys/language.h +21 -0
  215. data/src/external/Z/API/Z/keys/layout.h +20 -0
  216. data/src/external/Z/API/Z/keys/mathematics/geometry.h +29 -0
  217. data/src/external/Z/API/Z/keys/mathematics/number.h +21 -0
  218. data/src/external/Z/API/Z/keys/order.h +18 -0
  219. data/src/external/Z/API/Z/keys/platform.h +87 -0
  220. data/src/external/Z/API/Z/keys/program.h +39 -0
  221. data/src/external/Z/API/Z/keys/science/chemical elements.h +200 -0
  222. data/src/external/Z/API/Z/keys/science/electricity.h +18 -0
  223. data/src/external/Z/API/Z/keys/science/magnetism.h +19 -0
  224. data/src/external/Z/API/Z/keys/status.h +69 -0
  225. data/src/external/Z/API/Z/keys/text.h +27 -0
  226. data/src/external/Z/API/Z/keys/value.h +88 -0
  227. data/src/external/Z/API/Z/macros/arguments.h +25 -0
  228. data/src/external/Z/API/Z/macros/casting.h +22 -0
  229. data/src/external/Z/API/Z/macros/character.h +159 -0
  230. data/src/external/Z/API/Z/macros/date.h +14 -0
  231. data/src/external/Z/API/Z/macros/key.h +20 -0
  232. data/src/external/Z/API/Z/macros/language.h +126 -0
  233. data/src/external/Z/API/Z/macros/language.hpp +81 -0
  234. data/src/external/Z/API/Z/macros/members.h +86 -0
  235. data/src/external/Z/API/Z/macros/pasting.h +308 -0
  236. data/src/external/Z/API/Z/macros/pointer.h +33 -0
  237. data/src/external/Z/API/Z/macros/repetition.h +283 -0
  238. data/src/external/Z/API/Z/macros/structure.h +104 -0
  239. data/src/external/Z/API/Z/macros/templating.h +407 -0
  240. data/src/external/Z/API/Z/macros/tokens.h +14 -0
  241. data/src/external/Z/API/Z/macros/type enumeration.h +43 -0
  242. data/src/external/Z/API/Z/macros/type selection.hpp +76 -0
  243. data/src/external/Z/API/Z/macros/value.h +489 -0
  244. data/src/external/Z/API/Z/macros/variadic pasting.h +21 -0
  245. data/src/external/Z/API/Z/macros/variadic selection.h +56 -0
  246. data/src/external/Z/API/Z/macros/variadic.h +46 -0
  247. data/src/external/Z/API/Z/macros/version.h +17 -0
  248. data/src/external/Z/API/Z/network/3/IP.h +36 -0
  249. data/src/external/Z/API/Z/network/4/TCP.h +24 -0
  250. data/src/external/Z/API/Z/network/4/UDP.h +26 -0
  251. data/src/external/Z/API/Z/network/7/ED2K.h +104 -0
  252. data/src/external/Z/API/Z/network/7/HTTP.h +100 -0
  253. data/src/external/Z/API/Z/traits/SelectType.hpp +71 -0
  254. data/src/external/Z/API/Z/traits/TernaryType.hpp +20 -0
  255. data/src/external/Z/API/Z/traits/Type.hpp +4516 -0
  256. data/src/external/Z/API/Z/traits/TypeCount.hpp +52 -0
  257. data/src/external/Z/API/Z/traits/TypeList.hpp +376 -0
  258. data/src/external/Z/API/Z/traits/base.hpp +19 -0
  259. data/src/external/Z/API/Z/traits/filtering.hpp +30 -0
  260. data/src/external/Z/API/Z/traits/mathematics.hpp +48 -0
  261. data/src/external/Z/API/Z/types/arguments.h +19 -0
  262. data/src/external/Z/API/Z/types/base.h +1655 -0
  263. data/src/external/Z/API/Z/types/base.hpp +169 -0
  264. data/src/external/Z/API/Z/types/buffering.h +27 -0
  265. data/src/external/Z/API/Z/types/mathematics.h +135 -0
  266. data/src/external/Z/API/Z/types/time.h +23 -0
  267. data/src/external/Z/COPYING.LESSER +165 -0
  268. data/src/external/Z/development/Qt Creator/Z.pro +253 -0
  269. data/src/external/Z/distribution/CocoaPods/Zeta.podspec +18 -0
  270. data/src/external/Z/distribution/Gentoo Linux/Zeta-0.1.ebuild +22 -0
  271. data/src/external/Z/distribution/Gentoo Linux/metadata.xml +8 -0
  272. data/src/external/Z/distribution/Homebrew/Zeta.rb +11 -0
  273. data/src/external/z80/API/emulation/CPU/Z80.h +201 -0
  274. data/src/external/z80/README.md +229 -0
  275. data/src/external/z80/building/premake4.lua +33 -0
  276. data/src/external/z80/development/Xcode/Z80.xcodeproj/project.pbxproj +520 -0
  277. data/src/external/z80/sources/Z80.c +1660 -0
  278. data/src/interrupt.c +6 -0
  279. data/src/interrupt.h +3 -0
  280. data/src/io.c.erb +115 -0
  281. data/src/io.h.erb +18 -0
  282. data/src/main.c +69 -0
  283. data/src/memory.c.erb +43 -0
  284. data/src/memory.h.erb +9 -0
  285. metadata +329 -0
@@ -0,0 +1,1655 @@
1
+ /* Z Kit - types/base.h
2
+ _____ _______________
3
+ /_ /_/ -_/_ _/ _ |
4
+ /____/\___/ /__//___/_| Kit
5
+ Copyright (C) 2006-2018 Manuel Sainz de Baranda y Goñi.
6
+ Released under the terms of the GNU Lesser General Public License v3. */
7
+
8
+ #ifndef _Z_types_base_H_
9
+ #define _Z_types_base_H_
10
+
11
+ #include <Z/inspection/CPU.h>
12
+ #include <Z/inspection/floating-point.h>
13
+ #include <Z/inspection/data model.h>
14
+ #include <Z/macros/templating.h>
15
+ #include <Z/macros/structure.h>
16
+ #include <Z/macros/members.h>
17
+
18
+ /* MARK: - Fixed width numeric types */
19
+
20
+ typedef Z_DATA_MODEL_TYPE(UINT8) zuint8;
21
+ typedef struct {zuint8 x, y;} Z2DUInt8;
22
+ typedef struct {zuint8 x, y, z;} Z3DUInt8;
23
+ typedef struct {zuint8 x, y, z, w;} Z4DUInt8;
24
+ #define Z_UINT8 Z_DATA_MODEL_LITERAL (UINT8)
25
+ #define Z_UINT8_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(UINT8)
26
+ #define Z_UINT8_FIXED_VALUE_TYPE Z_VALUE_TYPE_UINT8
27
+ #define Z_UINT8_VALUE_FORMAT Z_VALUE_FORMAT_8BIT_NATURAL
28
+ #define Z_UINT8_BITS 8
29
+ #define Z_UINT8_SIZE 1
30
+ #define Z_UINT8_MINIMUM Z_UINT8(0)
31
+ #define Z_UINT8_MAXIMUM Z_UINT8(255)
32
+
33
+ typedef Z_DATA_MODEL_TYPE(SINT8) zsint8;
34
+ typedef struct {zsint8 x, y;} Z2DSInt8;
35
+ typedef struct {zsint8 x, y, z;} Z3DSInt8;
36
+ typedef struct {zsint8 x, y, z, w;} Z4DSInt8;
37
+ #define Z_SINT8 Z_DATA_MODEL_LITERAL (SINT8)
38
+ #define Z_SINT8_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(SINT8)
39
+ #define Z_SINT8_FIXED_VALUE_TYPE Z_VALUE_TYPE_SINT8
40
+ #define Z_SINT8_VALUE_FORMAT Z_CPU_FORMAT(INTEGER, 8)
41
+ #define Z_SINT8_BITS 8
42
+ #define Z_SINT8_SIZE 1
43
+ #define Z_SINT8_MINIMUM Z_SINT8(-128)
44
+ #define Z_SINT8_MAXIMUM Z_SINT8( 127)
45
+
46
+ typedef Z_DATA_MODEL_TYPE(UINT16) zuint16;
47
+ typedef struct {zuint16 x, y;} Z2DUInt16;
48
+ typedef struct {zuint16 x, y, z;} Z3DUInt16;
49
+ typedef struct {zuint16 x, y, z, w;} Z4DUInt16;
50
+ #define Z_UINT16 Z_DATA_MODEL_LITERAL (UINT16)
51
+ #define Z_UINT16_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(UINT16)
52
+ #define Z_UINT16_FIXED_VALUE_TYPE Z_VALUE_TYPE_UINT16
53
+ #define Z_UINT16_VALUE_FORMAT Z_VALUE_FORMAT_16BIT_NATURAL
54
+ #define Z_UINT16_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 16)
55
+ #define Z_UINT16_BITS 16
56
+ #define Z_UINT16_SIZE 2
57
+ #define Z_UINT16_MINIMUM Z_UINT16(0)
58
+ #define Z_UINT16_MAXIMUM Z_UINT16(65535)
59
+
60
+ typedef Z_DATA_MODEL_TYPE(SINT16) zsint16;
61
+ typedef struct {zsint16 x, y;} Z2DSInt16;
62
+ typedef struct {zsint16 x, y, z;} Z3DSInt16;
63
+ typedef struct {zsint16 x, y, z, w;} Z4DSInt16;
64
+ #define Z_SINT16 Z_DATA_MODEL_LITERAL (SINT16)
65
+ #define Z_SINT16_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(SINT16)
66
+ #define Z_SINT16_FIXED_VALUE_TYPE Z_VALUE_TYPE_SINT16
67
+ #define Z_SINT16_VALUE_FORMAT Z_CPU_FORMAT (INTEGER, 16)
68
+ #define Z_SINT16_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 16)
69
+ #define Z_SINT16_BITS 16
70
+ #define Z_SINT16_SIZE 2
71
+ #define Z_SINT16_MINIMUM Z_SINT16(-32768)
72
+ #define Z_SINT16_MAXIMUM Z_SINT16( 32767)
73
+
74
+ typedef Z_DATA_MODEL_TYPE(UINT32) zuint32;
75
+ typedef struct {zuint32 x, y;} Z2DUInt32;
76
+ typedef struct {zuint32 x, y, z;} Z3DUInt32;
77
+ typedef struct {zuint32 x, y, z, w;} Z4DUInt32;
78
+ #define Z_UINT32 Z_DATA_MODEL_LITERAL (UINT32)
79
+ #define Z_UINT32_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(UINT32)
80
+ #define Z_UINT32_FIXED_VALUE_TYPE Z_VALUE_TYPE_UINT32
81
+ #define Z_UINT32_VALUE_FORMAT Z_VALUE_FORMAT_32BIT_NATURAL
82
+ #define Z_UINT32_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 32)
83
+ #define Z_UINT32_BITS 32
84
+ #define Z_UINT32_SIZE 4
85
+ #define Z_UINT32_MINIMUM Z_UINT32(0)
86
+ #define Z_UINT32_MAXIMUM Z_UINT32(4294967295)
87
+
88
+ typedef Z_DATA_MODEL_TYPE(SINT32) zsint32;
89
+ typedef struct {zsint32 x, y;} Z2DSInt32;
90
+ typedef struct {zsint32 x, y, z;} Z3DSInt32;
91
+ typedef struct {zsint32 x, y, z, w;} Z4DSInt32;
92
+ #define Z_SINT32 Z_DATA_MODEL_LITERAL (SINT32)
93
+ #define Z_SINT32_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(SINT32)
94
+ #define Z_SINT32_FIXED_VALUE_TYPE Z_VALUE_TYPE_SINT32
95
+ #define Z_SINT32_VALUE_FORMAT Z_CPU_FORMAT (INTEGER, 32)
96
+ #define Z_SINT32_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 32)
97
+ #define Z_SINT32_BITS 32
98
+ #define Z_SINT32_SIZE 4
99
+ #define Z_SINT32_MINIMUM Z_SINT32(-2147483648)
100
+ #define Z_SINT32_MAXIMUM Z_SINT32( 2147483647)
101
+
102
+ #if Z_DATA_MODEL_HAS_TYPE(UINT64)
103
+
104
+ typedef Z_DATA_MODEL_TYPE(UINT64) zuint64;
105
+ typedef struct {zuint64 x, y;} Z2DUInt64;
106
+ typedef struct {zuint64 x, y, z;} Z3DUInt64;
107
+ typedef struct {zuint64 x, y, z, w;} Z4DUInt64;
108
+ # define Z_UINT64_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(UINT64)
109
+ # define Z_UINT64_FIXED_VALUE_TYPE Z_VALUE_TYPE_UINT64
110
+ # define Z_UINT64_VALUE_FORMAT Z_VALUE_FORMAT_64BIT_NATURAL
111
+ # define Z_UINT64_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 64)
112
+ # define Z_UINT64_BITS 64
113
+ # define Z_UINT64_SIZE 8
114
+ # define Z_UINT64_MINIMUM 0
115
+
116
+ # if Z_DATA_MODEL_HAS_LITERAL(UINT64)
117
+ # define Z_UINT64 Z_DATA_MODEL_LITERAL(UINT64)
118
+ # define Z_UINT64_MAXIMUM Z_UINT64(18446744073709551615)
119
+ # else
120
+ # define Z_UINT64 Z_SAME
121
+ # define Z_UINT64_MAXIMUM (((zuint64)0) - 1)
122
+ # endif
123
+
124
+ #endif
125
+
126
+ #if Z_DATA_MODEL_HAS_TYPE(SINT64)
127
+
128
+ typedef Z_DATA_MODEL_TYPE(SINT64) zsint64;
129
+ typedef struct {zsint64 x, y;} Z2DSInt64;
130
+ typedef struct {zsint64 x, y, z;} Z3DSInt64;
131
+ typedef struct {zsint64 x, y, z, w;} Z4DSInt64;
132
+ # define Z_SINT64_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(SINT64)
133
+ # define Z_SINT64_FIXED_VALUE_TYPE Z_VALUE_TYPE_SINT64
134
+ # define Z_SINT64_VALUE_FORMAT Z_CPU_FORMAT (INTEGER, 64)
135
+ # define Z_SINT64_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 64)
136
+ # define Z_SINT64_BITS 64
137
+ # define Z_SINT64_SIZE 8
138
+
139
+ # if Z_DATA_MODEL_HAS_LITERAL(SINT64)
140
+ # define Z_SINT64 Z_DATA_MODEL_LITERAL(SINT64)
141
+ # define Z_SINT64_MAXIMUM Z_SINT64(9223372036854775807)
142
+ # define Z_SINT64_MINIMUM (-Z_SINT64_MAXIMUM - Z_SINT64(1))
143
+ # else
144
+ # define Z_SINT64 Z_SAME
145
+ # define Z_SINT64_MAXIMUM 0 /* TODO */
146
+ # define Z_SINT64_MINIMUM 0 /* TODO */
147
+ # endif
148
+
149
+ #endif
150
+
151
+ #if Z_DATA_MODEL_HAS_TYPE(UINT128)
152
+
153
+ typedef Z_DATA_MODEL_TYPE(UINT128) zuint128;
154
+ typedef struct {zuint128 x, y;} Z2DUInt128;
155
+ typedef struct {zuint128 x, y, z;} Z3DUInt128;
156
+ typedef struct {zuint128 x, y, z, w;} Z4DUInt128;
157
+ # define Z_UINT128_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(UINT128)
158
+ # define Z_UINT128_FIXED_VALUE_TYPE Z_VALUE_TYPE_UINT128
159
+ # define Z_UINT128_VALUE_FORMAT Z_VALUE_FORMAT_128BIT_NATURAL
160
+ # define Z_UINT128_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 128)
161
+ # define Z_UINT128_BITS 128
162
+ # define Z_UINT128_SIZE 16
163
+ # define Z_UINT128_MINIMUM 0
164
+
165
+ # if Z_DATA_MODEL_HAS_LITERAL(UINT128)
166
+ # define Z_UINT128 Z_DATA_MODEL_LITERAL(UINT128)
167
+ # define Z_UINT128_MAXIMUM Z_UINT128(340282366920938463463374607431768211455)
168
+ # else
169
+ # define Z_UINT128 Z_SAME
170
+ # define Z_UINT128_MAXIMUM (((zuint128)0) - 1)
171
+ # endif
172
+
173
+ #endif
174
+
175
+ #if Z_DATA_MODEL_HAS_TYPE(SINT128)
176
+
177
+ typedef Z_DATA_MODEL_TYPE(SINT128) zsint128;
178
+ typedef struct {zsint128 x, y;} Z2DSInt128;
179
+ typedef struct {zsint128 x, y, z;} Z3DSInt128;
180
+ typedef struct {zsint128 x, y, z, w;} Z4DSInt128;
181
+ # define Z_SINT128_VALUE_TYPE Z_DATA_MODEL_VALUE_TYPE(SINT128)
182
+ # define Z_SINT128_FIXED_VALUE_TYPE Z_VALUE_TYPE_SINT128
183
+ # define Z_SINT128_VALUE_FORMAT Z_CPU_FORMAT (INTEGER, 128)
184
+ # define Z_SINT128_ENDIANNESS Z_CPU_ENDIANNESS(INTEGER, 128)
185
+ # define Z_SINT128_BITS 128
186
+ # define Z_SINT128_SIZE 16
187
+
188
+ # if Z_DATA_MODEL_HAS_LITERAL(SINT128)
189
+ # define Z_SINT128 Z_DATA_MODEL_LITERAL(SINT128)
190
+ # define Z_SINT128_MAXIMUM Z_SINT128(170141183460469231731687303715884105727)
191
+ # define Z_SINT128_MINIMUM (-Z_SINT128_MAXIMUM - Z_SINT128(1))
192
+ # else
193
+ # define Z_SINT128 Z_SAME
194
+ # define Z_SINT128_MAXIMUM 0 /* TODO */
195
+ # define Z_SINT128_MINIMUM 0 /* TODO */
196
+ # endif
197
+
198
+ #endif
199
+
200
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT16)
201
+
202
+ typedef Z_FLOATING_POINT_TYPE(FLOAT16) zfloat16;
203
+ typedef struct {zfloat16 x, y;} Z2DFloat16;
204
+ typedef struct {zfloat16 x, y, z;} Z3DFloat16;
205
+ typedef struct {zfloat16 x, y, z, w;} Z4DFloat16;
206
+ # define Z_FLOAT16 Z_FLOATING_POINT_LITERAL (FLOAT16)
207
+ # define Z_FLOAT16_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT16)
208
+ # define Z_FLOAT16_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT16
209
+ # define Z_FLOAT16_VALUE_FORMAT Z_VALUE_FORMAT_IEEE_754_BINARY16
210
+ # define Z_FLOAT16_BITS 16
211
+ # define Z_FLOAT16_SIZE 2
212
+ # define Z_FLOAT16_BIAS Z_FLOATING_POINT_BIAS (FLOAT16)
213
+ # define Z_FLOAT16_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT16)
214
+ # define Z_FLOAT16_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT16)
215
+ # define Z_FLOAT16_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT16)
216
+ # define Z_FLOAT16_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT16)
217
+ # define Z_FLOAT16_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT16)
218
+ # define Z_FLOAT16_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT16)
219
+ # define Z_FLOAT16_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT16)
220
+ # define Z_FLOAT16_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT16)
221
+ # define Z_FLOAT16_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT16)
222
+ # define Z_FLOAT16_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT16)
223
+ # define Z_FLOAT16_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT16)
224
+ # define Z_FLOAT16_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT16)
225
+ # define Z_FLOAT16_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT16)
226
+ # define Z_FLOAT16_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT16)
227
+ # define Z_FLOAT16_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT16)
228
+ # define Z_FLOAT16_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT16)
229
+ # define Z_FLOAT16_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT16)
230
+ # define Z_FLOAT16_NAN Z_FLOATING_POINT_NAN (FLOAT16)
231
+
232
+ #endif
233
+
234
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT32)
235
+
236
+ typedef Z_FLOATING_POINT_TYPE(FLOAT32) zfloat32;
237
+ typedef struct {zfloat32 x, y;} Z2DFloat32;
238
+ typedef struct {zfloat32 x, y, z;} Z3DFloat32;
239
+ typedef struct {zfloat32 x, y, z, w;} Z4DFloat32;
240
+ # define Z_FLOAT32 Z_FLOATING_POINT_LITERAL (FLOAT32)
241
+ # define Z_FLOAT32_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT32)
242
+ # define Z_FLOAT32_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT32
243
+ # define Z_FLOAT32_VALUE_FORMAT Z_VALUE_FORMAT_IEEE_754_BINARY32
244
+ # define Z_FLOAT32_BITS 32
245
+ # define Z_FLOAT32_SIZE 4
246
+ # define Z_FLOAT32_BIAS Z_FLOATING_POINT_BIAS (FLOAT32)
247
+ # define Z_FLOAT32_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT32)
248
+ # define Z_FLOAT32_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT32)
249
+ # define Z_FLOAT32_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT32)
250
+ # define Z_FLOAT32_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT32)
251
+ # define Z_FLOAT32_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT32)
252
+ # define Z_FLOAT32_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT32)
253
+ # define Z_FLOAT32_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT32)
254
+ # define Z_FLOAT32_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT32)
255
+ # define Z_FLOAT32_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT32)
256
+ # define Z_FLOAT32_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT32)
257
+ # define Z_FLOAT32_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT32)
258
+ # define Z_FLOAT32_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT32)
259
+ # define Z_FLOAT32_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT32)
260
+ # define Z_FLOAT32_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT32)
261
+ # define Z_FLOAT32_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT32)
262
+ # define Z_FLOAT32_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT32)
263
+ # define Z_FLOAT32_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT32)
264
+ # define Z_FLOAT32_NAN Z_FLOATING_POINT_NAN (FLOAT32)
265
+
266
+ #endif
267
+
268
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT64)
269
+
270
+ typedef Z_FLOATING_POINT_TYPE(FLOAT64) zfloat64;
271
+ typedef struct {zfloat64 x, y;} Z2DFloat64;
272
+ typedef struct {zfloat64 x, y, z;} Z3DFloat64;
273
+ typedef struct {zfloat64 x, y, z, w;} Z4DFloat64;
274
+ # define Z_FLOAT64 Z_FLOATING_POINT_LITERAL (FLOAT64)
275
+ # define Z_FLOAT64_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT64)
276
+ # define Z_FLOAT64_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT64
277
+ # define Z_FLOAT64_VALUE_FORMAT Z_VALUE_FORMAT_IEEE_754_BINARY64
278
+ # define Z_FLOAT64_BITS 64
279
+ # define Z_FLOAT64_SIZE 8
280
+ # define Z_FLOAT64_BIAS Z_FLOATING_POINT_BIAS (FLOAT64)
281
+ # define Z_FLOAT64_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT64)
282
+ # define Z_FLOAT64_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT64)
283
+ # define Z_FLOAT64_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT64)
284
+ # define Z_FLOAT64_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT64)
285
+ # define Z_FLOAT64_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT64)
286
+ # define Z_FLOAT64_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT64)
287
+ # define Z_FLOAT64_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT64)
288
+ # define Z_FLOAT64_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT64)
289
+ # define Z_FLOAT64_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT64)
290
+ # define Z_FLOAT64_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT64)
291
+ # define Z_FLOAT64_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT64)
292
+ # define Z_FLOAT64_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT64)
293
+ # define Z_FLOAT64_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT64)
294
+ # define Z_FLOAT64_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT64)
295
+ # define Z_FLOAT64_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT64)
296
+ # define Z_FLOAT64_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT64)
297
+ # define Z_FLOAT64_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT64)
298
+ # define Z_FLOAT64_NAN Z_FLOATING_POINT_NAN (FLOAT64)
299
+
300
+ #endif
301
+
302
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT128)
303
+
304
+ typedef Z_FLOATING_POINT_TYPE(FLOAT128) zfloat128;
305
+ typedef struct {zfloat128 x, y;} Z2DFloat128;
306
+ typedef struct {zfloat128 x, y, z;} Z3DFloat128;
307
+ typedef struct {zfloat128 x, y, z, w;} Z4DFloat128;
308
+ # define Z_FLOAT128 Z_FLOATING_POINT_LITERAL (FLOAT128)
309
+ # define Z_FLOAT128_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT128)
310
+ # define Z_FLOAT128_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT128
311
+ # define Z_FLOAT128_VALUE_FORMAT Z_VALUE_FORMAT_IEEE_754_BINARY128
312
+ # define Z_FLOAT128_BITS 128
313
+ # define Z_FLOAT128_SIZE 16
314
+ # define Z_FLOAT128_BIAS Z_FLOATING_POINT_BIAS (FLOAT128)
315
+ # define Z_FLOAT128_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT128)
316
+ # define Z_FLOAT128_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT128)
317
+ # define Z_FLOAT128_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT128)
318
+ # define Z_FLOAT128_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT128)
319
+ # define Z_FLOAT128_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT128)
320
+ # define Z_FLOAT128_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT128)
321
+ # define Z_FLOAT128_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT128)
322
+ # define Z_FLOAT128_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT128)
323
+ # define Z_FLOAT128_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT128)
324
+ # define Z_FLOAT128_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT128)
325
+ # define Z_FLOAT128_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT128)
326
+ # define Z_FLOAT128_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT128)
327
+ # define Z_FLOAT128_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT128)
328
+ # define Z_FLOAT128_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT128)
329
+ # define Z_FLOAT128_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT128)
330
+ # define Z_FLOAT128_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT128)
331
+ # define Z_FLOAT128_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT128)
332
+ # define Z_FLOAT128_NAN Z_FLOATING_POINT_NAN (FLOAT128)
333
+
334
+ #endif
335
+
336
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT80_X87)
337
+
338
+ typedef Z_FLOATING_POINT_TYPE(FLOAT80_X87) zfloat80_x87;
339
+ typedef struct {zfloat80_x87 x, y;} Z2DFloat80_x87;
340
+ typedef struct {zfloat80_x87 x, y, z;} Z3DFloat80_x87;
341
+ typedef struct {zfloat80_x87 x, y, z, w;} Z4DFloat80_x87;
342
+ # define Z_FLOAT80_X87 Z_FLOATING_POINT_LITERAL (FLOAT80_X87)
343
+ # define Z_FLOAT80_X87_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT80_X87)
344
+ # define Z_FLOAT80_X87_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT80_X87
345
+ # define Z_FLOAT80_X87_VALUE_FORMAT Z_VALUE_FORMAT_X87_BINARY80
346
+ # define Z_FLOAT80_X87_BITS 80
347
+ # define Z_FLOAT80_X87_SIZE 10
348
+ # define Z_FLOAT80_X87_BIAS Z_FLOATING_POINT_BIAS (FLOAT80_X87)
349
+ # define Z_FLOAT80_X87_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT80_X87)
350
+ # define Z_FLOAT80_X87_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT80_X87)
351
+ # define Z_FLOAT80_X87_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT80_X87)
352
+ # define Z_FLOAT80_X87_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT80_X87)
353
+ # define Z_FLOAT80_X87_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT80_X87)
354
+ # define Z_FLOAT80_X87_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT80_X87)
355
+ # define Z_FLOAT80_X87_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT80_X87)
356
+ # define Z_FLOAT80_X87_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT80_X87)
357
+ # define Z_FLOAT80_X87_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT80_X87)
358
+ # define Z_FLOAT80_X87_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT80_X87)
359
+ # define Z_FLOAT80_X87_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT80_X87)
360
+ # define Z_FLOAT80_X87_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT80_X87)
361
+ # define Z_FLOAT80_X87_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT80_X87)
362
+ # define Z_FLOAT80_X87_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT80_X87)
363
+ # define Z_FLOAT80_X87_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT80_X87)
364
+ # define Z_FLOAT80_X87_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT80_X87)
365
+ # define Z_FLOAT80_X87_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT80_X87)
366
+ # define Z_FLOAT80_X87_NAN Z_FLOATING_POINT_NAN (FLOAT80_X87)
367
+
368
+ #endif
369
+
370
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT96_X87)
371
+
372
+ typedef Z_FLOATING_POINT_TYPE(FLOAT96_X87) zfloat96_x87;
373
+ typedef struct {zfloat96_x87 x, y;} Z2DFloat96_x87;
374
+ typedef struct {zfloat96_x87 x, y, z;} Z3DFloat96_x87;
375
+ typedef struct {zfloat96_x87 x, y, z, w;} Z4DFloat96_x87;
376
+ # define Z_FLOAT96_X87 Z_FLOATING_POINT_LITERAL (FLOAT96_X87)
377
+ # define Z_FLOAT96_X87_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT96_X87)
378
+ # define Z_FLOAT96_X87_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT96_X87
379
+ # define Z_FLOAT96_X87_VALUE_FORMAT Z_VALUE_FORMAT_X87_BINARY96
380
+ # define Z_FLOAT96_X87_BITS 96
381
+ # define Z_FLOAT96_X87_SIZE 12
382
+ # define Z_FLOAT96_X87_BIAS Z_FLOATING_POINT_BIAS (FLOAT96_X87)
383
+ # define Z_FLOAT96_X87_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT96_X87)
384
+ # define Z_FLOAT96_X87_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT96_X87)
385
+ # define Z_FLOAT96_X87_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT96_X87)
386
+ # define Z_FLOAT96_X87_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT96_X87)
387
+ # define Z_FLOAT96_X87_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT96_X87)
388
+ # define Z_FLOAT96_X87_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT96_X87)
389
+ # define Z_FLOAT96_X87_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT96_X87)
390
+ # define Z_FLOAT96_X87_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT96_X87)
391
+ # define Z_FLOAT96_X87_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT96_X87)
392
+ # define Z_FLOAT96_X87_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT96_X87)
393
+ # define Z_FLOAT96_X87_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT96_X87)
394
+ # define Z_FLOAT96_X87_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT96_X87)
395
+ # define Z_FLOAT96_X87_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT96_X87)
396
+ # define Z_FLOAT96_X87_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT96_X87)
397
+ # define Z_FLOAT96_X87_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT96_X87)
398
+ # define Z_FLOAT96_X87_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT96_X87)
399
+ # define Z_FLOAT96_X87_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT96_X87)
400
+ # define Z_FLOAT96_X87_NAN Z_FLOATING_POINT_NAN (FLOAT96_X87)
401
+
402
+ #endif
403
+
404
+ #if Z_FLOATING_POINT_HAS_TYPE(FLOAT128_X87)
405
+
406
+ typedef Z_FLOATING_POINT_TYPE(FLOAT128_X87) zfloat128_x87;
407
+ typedef struct {zfloat128_x87 x, y;} Z2DFloat128_x87;
408
+ typedef struct {zfloat128_x87 x, y, z;} Z3DFloat128_x87;
409
+ typedef struct {zfloat128_x87 x, y, z, w;} Z4DFloat128_x87;
410
+ # define Z_FLOAT128_X87 Z_FLOATING_POINT_LITERAL (FLOAT128_X87)
411
+ # define Z_FLOAT128_X87_VALUE_TYPE Z_FLOATING_POINT_VALUE_TYPE (FLOAT128_X87)
412
+ # define Z_FLOAT128_X87_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT128_X87
413
+ # define Z_FLOAT128_X87_VALUE_FORMAT Z_VALUE_FORMAT_X87_BINARY128
414
+ # define Z_FLOAT128_X87_BITS 128
415
+ # define Z_FLOAT128_X87_SIZE 16
416
+ # define Z_FLOAT128_X87_BIAS Z_FLOATING_POINT_BIAS (FLOAT128_X87)
417
+ # define Z_FLOAT128_X87_DECIMAL_DIGITS Z_FLOATING_POINT_DECIMAL_DIGITS (FLOAT128_X87)
418
+ # define Z_FLOAT128_X87_SIGNIFICAND_OFFSET Z_FLOATING_POINT_SIGNIFICAND_OFFSET (FLOAT128_X87)
419
+ # define Z_FLOAT128_X87_SIGNIFICAND_BITS Z_FLOATING_POINT_SIGNIFICAND_BITS (FLOAT128_X87)
420
+ # define Z_FLOAT128_X87_SIGNIFICAND_DIGITS Z_FLOATING_POINT_SIGNIFICAND_DIGITS (FLOAT128_X87)
421
+ # define Z_FLOAT128_X87_EXPONENT_OFFSET Z_FLOATING_POINT_EXPONENT_OFFSET (FLOAT128_X87)
422
+ # define Z_FLOAT128_X87_EXPONENT_BITS Z_FLOATING_POINT_EXPONENT_BITS (FLOAT128_X87)
423
+ # define Z_FLOAT128_X87_EXPONENT_RADIX Z_FLOATING_POINT_EXPONENT_RADIX (FLOAT128_X87)
424
+ # define Z_FLOAT128_X87_EXPONENT_MINIMUM Z_FLOATING_POINT_EXPONENT_MINIMUM (FLOAT128_X87)
425
+ # define Z_FLOAT128_X87_EXPONENT_MAXIMUM Z_FLOATING_POINT_EXPONENT_MAXIMUM (FLOAT128_X87)
426
+ # define Z_FLOAT128_X87_EXPONENT_10_MINIMUM Z_FLOATING_POINT_EXPONENT_10_MINIMUM(FLOAT128_X87)
427
+ # define Z_FLOAT128_X87_EXPONENT_10_MAXIMUM Z_FLOATING_POINT_EXPONENT_10_MAXIMUM(FLOAT128_X87)
428
+ # define Z_FLOAT128_X87_SIGN_OFFSET Z_FLOATING_POINT_SIGN_OFFSET (FLOAT128_X87)
429
+ # define Z_FLOAT128_X87_SIGN_BITS Z_FLOATING_POINT_SIGN_BITS (FLOAT128_X87)
430
+ # define Z_FLOAT128_X87_EPSILON Z_FLOATING_POINT_EPSILON (FLOAT128_X87)
431
+ # define Z_FLOAT128_X87_MINIMUM Z_FLOATING_POINT_MINIMUM (FLOAT128_X87)
432
+ # define Z_FLOAT128_X87_MAXIMUM Z_FLOATING_POINT_MAXIMUM (FLOAT128_X87)
433
+ # define Z_FLOAT128_X87_INFINITY Z_FLOATING_POINT_INFINITY (FLOAT128_X87)
434
+ # define Z_FLOAT128_X87_NAN Z_FLOATING_POINT_NAN (FLOAT128_X87)
435
+
436
+ #endif
437
+
438
+ #define ztype( TYPE) Z_APPEND_##TYPE##_fixed_type(z )
439
+ #define Z2DType( TYPE) Z_APPEND_##TYPE##_FixedType (Z2D)
440
+ #define Z3DType( TYPE) Z_APPEND_##TYPE##_FixedType (Z3D)
441
+ #define Z4DType( TYPE) Z_APPEND_##TYPE##_FixedType (Z4D)
442
+ #define Z_TYPE( TYPE) Z_APPEND_##TYPE##_FIXED_TYPE(Z_ )
443
+ #define Z_TYPE_VALUE_TYPE( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _VALUE_TYPE )
444
+ #define Z_TYPE_FIXED_VALUE_TYPE( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _FIXED_VALUE_TYPE )
445
+ #define Z_TYPE_VALUE_FORMAT( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _VALUE_FORMAT )
446
+ #define Z_TYPE_ENDIANNESS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _ENDIANNESS )
447
+ #define Z_TYPE_BITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _BITS )
448
+ #define Z_TYPE_SIZE( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIZE )
449
+ #define Z_TYPE_BIAS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _BIAS )
450
+ #define Z_TYPE_DECIMAL_DIGITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _DECIMAL_DIGITS )
451
+ #define Z_TYPE_SIGNIFICAND_OFFSET( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIGNIFICAND_OFFSET )
452
+ #define Z_TYPE_SIGNIFICAND_BITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIGNIFICAND_BITS )
453
+ #define Z_TYPE_SIGNIFICAND_DIGITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIGNIFICAND_DIGITS )
454
+ #define Z_TYPE_EXPONENT_OFFSET( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_OFFSET )
455
+ #define Z_TYPE_EXPONENT_BITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_BITS )
456
+ #define Z_TYPE_EXPONENT_RADIX( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_RADIX )
457
+ #define Z_TYPE_EXPONENT_MINIMUM( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_MINIMUM )
458
+ #define Z_TYPE_EXPONENT_MAXIMUM( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_MAXIMUM )
459
+ #define Z_TYPE_EXPONENT_10_MINIMUM(TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_10_MINIMUM)
460
+ #define Z_TYPE_EXPONENT_10_MAXIMUM(TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EXPONENT_10_MAXIMUM)
461
+ #define Z_TYPE_SIGN_OFFSET( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIGN_OFFSET )
462
+ #define Z_TYPE_SIGN_BITS( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _SIGN_BITS )
463
+ #define Z_TYPE_EPSILON( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _EPSILON )
464
+ #define Z_TYPE_MINIMUM( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _MINIMUM )
465
+ #define Z_TYPE_MAXIMUM( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _MAXIMUM )
466
+ #define Z_TYPE_INFINITY( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _INFINITY )
467
+ #define Z_TYPE_NAN( TYPE) Z_INSERT_##TYPE##_FIXED_TYPE(Z_, _NAN )
468
+
469
+ /* MARK: - Fundamental types */
470
+
471
+ #if ('\0' - 1) > 0
472
+ # define Z_CHAR_IS_SIGNED FALSE
473
+ #else
474
+ # define Z_CHAR_IS_SIGNED TRUE
475
+ #endif
476
+
477
+ #define Z_CHAR_BITS Z_DATA_MODEL_BITS(CHAR)
478
+
479
+ typedef char zchar;
480
+ #define Z_CHAR Z_SAME
481
+ #define Z_CHAR_VALUE_TYPE Z_VALUE_TYPE_CHAR
482
+ #define Z_CHAR_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(CHAR)
483
+ #define Z_CHAR_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (CHAR)
484
+ #define Z_CHAR_SIZE Z_TYPE_SIZE (CHAR)
485
+ #define Z_CHAR_MINIMUM Z_TYPE_MINIMUM (CHAR)
486
+ #define Z_CHAR_MAXIMUM Z_TYPE_MAXIMUM (CHAR)
487
+
488
+ #define Z_UCHAR_BITS Z_DATA_MODEL_BITS(CHAR)
489
+
490
+ typedef unsigned char zuchar;
491
+ typedef Z2DType(UCHAR) Z2DUChar;
492
+ typedef Z3DType(UCHAR) Z3DUChar;
493
+ typedef Z4DType(UCHAR) Z4DUChar;
494
+ #define Z_UCHAR Z_SUFFIX_U
495
+ #define Z_UCHAR_VALUE_TYPE Z_VALUE_TYPE_UCHAR
496
+ #define Z_UCHAR_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(UCHAR)
497
+ #define Z_UCHAR_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (UCHAR)
498
+ #define Z_UCHAR_SIZE Z_TYPE_SIZE (UCHAR)
499
+ #define Z_UCHAR_MINIMUM Z_TYPE_MINIMUM (UCHAR)
500
+ #define Z_UCHAR_MAXIMUM Z_TYPE_MAXIMUM (UCHAR)
501
+
502
+ #define Z_SCHAR_BITS Z_DATA_MODEL_BITS(CHAR)
503
+
504
+ typedef signed char zschar;
505
+ typedef Z2DType(SCHAR) Z2DSChar;
506
+ typedef Z3DType(SCHAR) Z3DSChar;
507
+ typedef Z4DType(SCHAR) Z4DSChar;
508
+ #define Z_SCHAR Z_SAME
509
+ #define Z_SCHAR_VALUE_TYPE Z_VALUE_TYPE_SCHAR
510
+ #define Z_SCHAR_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SCHAR)
511
+ #define Z_SCHAR_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SCHAR)
512
+ #define Z_SCHAR_SIZE Z_TYPE_SIZE (SCHAR)
513
+ #define Z_SCHAR_MINIMUM Z_TYPE_MINIMUM (SCHAR)
514
+ #define Z_SCHAR_MAXIMUM Z_TYPE_MAXIMUM (SCHAR)
515
+
516
+ #define Z_USHORT_BITS Z_DATA_MODEL_BITS(SHORT)
517
+
518
+ typedef unsigned short int zushort;
519
+ typedef Z2DType(USHORT) Z2DUShort;
520
+ typedef Z3DType(USHORT) Z3DUShort;
521
+ typedef Z4DType(USHORT) Z4DUShort;
522
+ #define Z_USHORT Z_SUFFIX_U
523
+ #define Z_USHORT_VALUE_TYPE Z_VALUE_TYPE_USHORT
524
+ #define Z_USHORT_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(USHORT)
525
+ #define Z_USHORT_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (USHORT)
526
+ #define Z_USHORT_ENDIANNESS Z_TYPE_ENDIANNESS (USHORT)
527
+ #define Z_USHORT_SIZE Z_TYPE_SIZE (USHORT)
528
+ #define Z_USHORT_MINIMUM Z_TYPE_MINIMUM (USHORT)
529
+ #define Z_USHORT_MAXIMUM Z_TYPE_MAXIMUM (USHORT)
530
+
531
+ #define Z_SSHORT_BITS Z_DATA_MODEL_BITS(SHORT)
532
+
533
+ typedef signed short int zsshort;
534
+ typedef Z2DType(SSHORT) Z2DSShort;
535
+ typedef Z3DType(SSHORT) Z3DSShort;
536
+ typedef Z4DType(SSHORT) Z4DSShort;
537
+ #define Z_SSHORT Z_SAME
538
+ #define Z_SSHORT_VALUE_TYPE Z_VALUE_TYPE_SSHORT
539
+ #define Z_SSHORT_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SSHORT)
540
+ #define Z_SSHORT_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SSHORT)
541
+ #define Z_SSHORT_ENDIANNESS Z_TYPE_ENDIANNESS (SSHORT)
542
+ #define Z_SSHORT_SIZE Z_TYPE_SIZE (SSHORT)
543
+ #define Z_SSHORT_MINIMUM Z_TYPE_MINIMUM (SSHORT)
544
+ #define Z_SSHORT_MAXIMUM Z_TYPE_MAXIMUM (SSHORT)
545
+
546
+ #define Z_UINT_BITS Z_DATA_MODEL_BITS(INT)
547
+
548
+ typedef unsigned int zuint;
549
+ typedef Z2DType(UINT) Z2DUInt;
550
+ typedef Z3DType(UINT) Z3DUInt;
551
+ typedef Z4DType(UINT) Z4DUInt;
552
+ #define Z_UINT Z_SUFFIX_U
553
+ #define Z_UINT_VALUE_TYPE Z_VALUE_TYPE_UINT
554
+ #define Z_UINT_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(UINT)
555
+ #define Z_UINT_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (UINT)
556
+ #define Z_UINT_ENDIANNESS Z_TYPE_ENDIANNESS (UINT)
557
+ #define Z_UINT_SIZE Z_TYPE_SIZE (UINT)
558
+ #define Z_UINT_MINIMUM Z_TYPE_MINIMUM (UINT)
559
+ #define Z_UINT_MAXIMUM Z_TYPE_MAXIMUM (UINT)
560
+
561
+ #define Z_SINT_BITS Z_DATA_MODEL_BITS(INT)
562
+
563
+ typedef signed int zsint;
564
+ typedef Z2DType(SINT) Z2DSInt;
565
+ typedef Z3DType(SINT) Z3DSInt;
566
+ typedef Z4DType(SINT) Z4DSInt;
567
+ #define Z_SINT Z_SAME
568
+ #define Z_SINT_VALUE_TYPE Z_VALUE_TYPE_SINT
569
+ #define Z_SINT_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SINT)
570
+ #define Z_SINT_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SINT)
571
+ #define Z_SINT_ENDIANNESS Z_TYPE_ENDIANNESS (SINT)
572
+ #define Z_SINT_SIZE Z_TYPE_SIZE (SINT)
573
+ #define Z_SINT_MINIMUM Z_TYPE_MINIMUM (SINT)
574
+ #define Z_SINT_MAXIMUM Z_TYPE_MAXIMUM (SINT)
575
+
576
+ #define Z_ULONG_BITS Z_DATA_MODEL_BITS(LONG)
577
+
578
+ typedef unsigned long int zulong;
579
+ typedef Z2DType(ULONG) Z2DULong;
580
+ typedef Z3DType(ULONG) Z3DULong;
581
+ typedef Z4DType(ULONG) Z4DULong;
582
+ #define Z_ULONG Z_SUFFIX_UL
583
+ #define Z_ULONG_VALUE_TYPE Z_VALUE_TYPE_ULONG
584
+ #define Z_ULONG_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(ULONG)
585
+ #define Z_ULONG_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (ULONG)
586
+ #define Z_ULONG_ENDIANNESS Z_TYPE_ENDIANNESS (ULONG)
587
+ #define Z_ULONG_SIZE Z_TYPE_SIZE (ULONG)
588
+ #define Z_ULONG_MINIMUM Z_TYPE_MINIMUM (ULONG)
589
+ #define Z_ULONG_MAXIMUM Z_TYPE_MAXIMUM (ULONG)
590
+
591
+ #define Z_SLONG_BITS Z_DATA_MODEL_BITS(LONG)
592
+
593
+ typedef signed long int zslong;
594
+ typedef Z2DType(SLONG) Z2DSLong;
595
+ typedef Z3DType(SLONG) Z3DSLong;
596
+ typedef Z4DType(SLONG) Z4DSLong;
597
+ #define Z_SLONG Z_SUFFIX_L
598
+ #define Z_SLONG_VALUE_TYPE Z_VALUE_TYPE_SLONG
599
+ #define Z_SLONG_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SLONG)
600
+ #define Z_SLONG_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SLONG)
601
+ #define Z_SLONG_ENDIANNESS Z_TYPE_ENDIANNESS (SLONG)
602
+ #define Z_SLONG_SIZE Z_TYPE_SIZE (SLONG)
603
+ #define Z_SLONG_MINIMUM Z_TYPE_MINIMUM (SLONG)
604
+ #define Z_SLONG_MAXIMUM Z_TYPE_MAXIMUM (SLONG)
605
+
606
+ #if Z_LANGUAGE_HAS_TYPE(C, LLONG) || Z_LANGUAGE_HAS_TYPE(CPP, LLONG)
607
+
608
+ # define Z_ULLONG_BITS Z_DATA_MODEL_BITS(LLONG)
609
+
610
+ typedef unsigned long long int zullong;
611
+ typedef Z2DType(ULLONG) Z2DULLong;
612
+ typedef Z3DType(ULLONG) Z3DULLong;
613
+ typedef Z4DType(ULLONG) Z4DULLong;
614
+ # define Z_ULLONG Z_SUFFIX_LL
615
+ # define Z_ULLONG_VALUE_TYPE Z_VALUE_TYPE_ULLONG
616
+ # define Z_ULLONG_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(ULLONG)
617
+ # define Z_ULLONG_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (ULLONG)
618
+ # define Z_ULLONG_ENDIANNESS Z_TYPE_ENDIANNESS (ULLONG)
619
+ # define Z_ULLONG_SIZE Z_TYPE_SIZE (ULLONG)
620
+ # define Z_ULLONG_MINIMUM Z_TYPE_MINIMUM (ULLONG)
621
+ # define Z_ULLONG_MAXIMUM Z_TYPE_MAXIMUM (ULLONG)
622
+
623
+ # define Z_SLLONG_BITS Z_DATA_MODEL_BITS(LLONG)
624
+
625
+ typedef signed long long int zsllong;
626
+ typedef Z2DType(SLLONG) Z2DSLLong;
627
+ typedef Z3DType(SLLONG) Z3DSLLong;
628
+ typedef Z4DType(SLLONG) Z4DSLLong;
629
+ # define Z_SLLONG Z_SUFFIX_LL
630
+ # define Z_SLLONG_VALUE_TYPE Z_VALUE_TYPE_SLLONG
631
+ # define Z_SLLONG_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SLLONG)
632
+ # define Z_SLLONG_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SLLONG)
633
+ # define Z_SLLONG_ENDIANNESS Z_TYPE_ENDIANNESS (SLLONG)
634
+ # define Z_SLLONG_SIZE Z_TYPE_SIZE (SLLONG)
635
+ # define Z_SLLONG_MINIMUM Z_TYPE_MINIMUM (SLLONG)
636
+ # define Z_SLLONG_MAXIMUM Z_TYPE_MAXIMUM (SLLONG)
637
+
638
+ # define Z_LLONG
639
+
640
+ #endif
641
+
642
+ #if Z_LANGUAGE_HAS_TYPE(C, FLOAT)
643
+
644
+ # define Z_FLOAT_FIXED_VALUE_TYPE Z_FLOATING_POINT_FIXED_VALUE_TYPE(FLOAT)
645
+
646
+ typedef float zfloat;
647
+ typedef Z2DType(FLOAT) Z2DFloat;
648
+ typedef Z3DType(FLOAT) Z3DFloat;
649
+ typedef Z4DType(FLOAT) Z4DFloat;
650
+ # define Z_FLOAT Z_SUFFIX_F
651
+ # define Z_FLOAT_VALUE_TYPE Z_VALUE_TYPE_FLOAT
652
+ # define Z_FLOAT_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (FLOAT)
653
+ # define Z_FLOAT_BITS Z_TYPE_BITS (FLOAT)
654
+ # define Z_FLOAT_SIZE Z_TYPE_SIZE (FLOAT)
655
+ # define Z_FLOAT_BIAS Z_TYPE_BIAS (FLOAT)
656
+ # define Z_FLOAT_DECIMAL_DIGITS Z_TYPE_DECIMAL_DIGITS (FLOAT)
657
+ # define Z_FLOAT_SIGNIFICAND_OFFSET Z_TYPE_SIGNIFICAND_OFFSET (FLOAT)
658
+ # define Z_FLOAT_SIGNIFICAND_BITS Z_TYPE_SIGNIFICAND_BITS (FLOAT)
659
+ # define Z_FLOAT_SIGNIFICAND_DIGITS Z_TYPE_SIGNIFICAND_DIGITS (FLOAT)
660
+ # define Z_FLOAT_EXPONENT_OFFSET Z_TYPE_EXPONENT_OFFSET (FLOAT)
661
+ # define Z_FLOAT_EXPONENT_BITS Z_TYPE_EXPONENT_BITS (FLOAT)
662
+ # define Z_FLOAT_EXPONENT_RADIX Z_TYPE_EXPONENT_RADIX (FLOAT)
663
+ # define Z_FLOAT_EXPONENT_MINIMUM Z_TYPE_EXPONENT_MINIMUM (FLOAT)
664
+ # define Z_FLOAT_EXPONENT_MAXIMUM Z_TYPE_EXPONENT_MAXIMUM (FLOAT)
665
+ # define Z_FLOAT_EXPONENT_10_MINIMUM Z_TYPE_EXPONENT_10_MINIMUM(FLOAT)
666
+ # define Z_FLOAT_EXPONENT_10_MAXIMUM Z_TYPE_EXPONENT_10_MAXIMUM(FLOAT)
667
+ # define Z_FLOAT_SIGN_OFFSET Z_TYPE_SIGN_OFFSET (FLOAT)
668
+ # define Z_FLOAT_SIGN_BITS Z_TYPE_SIGN_BITS (FLOAT)
669
+ # define Z_FLOAT_EPSILON Z_TYPE_EPSILON (FLOAT)
670
+ # define Z_FLOAT_MINIMUM Z_TYPE_MINIMUM (FLOAT)
671
+ # define Z_FLOAT_MAXIMUM Z_TYPE_MAXIMUM (FLOAT)
672
+ # define Z_FLOAT_INFINITY Z_TYPE_INFINITY (FLOAT)
673
+ # define Z_FLOAT_NAN Z_TYPE_NAN (FLOAT)
674
+
675
+ #endif
676
+
677
+ #if Z_LANGUAGE_HAS_TYPE(C, DOUBLE)
678
+
679
+ # define Z_DOUBLE_FIXED_VALUE_TYPE Z_FLOATING_POINT_FIXED_VALUE_TYPE(DOUBLE)
680
+
681
+ typedef double zdouble;
682
+ typedef Z2DType(DOUBLE) Z2DDouble;
683
+ typedef Z3DType(DOUBLE) Z3DDouble;
684
+ typedef Z4DType(DOUBLE) Z4DDouble;
685
+ # define Z_DOUBLE Z_SAME
686
+ # define Z_DOUBLE_VALUE_TYPE Z_VALUE_TYPE_DOUBLE
687
+ # define Z_DOUBLE_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (DOUBLE)
688
+ # define Z_DOUBLE_BITS Z_TYPE_BITS (DOUBLE)
689
+ # define Z_DOUBLE_SIZE Z_TYPE_SIZE (DOUBLE)
690
+ # define Z_DOUBLE_BIAS Z_TYPE_BIAS (DOUBLE)
691
+ # define Z_DOUBLE_DECIMAL_DIGITS Z_TYPE_DECIMAL_DIGITS (DOUBLE)
692
+ # define Z_DOUBLE_SIGNIFICAND_OFFSET Z_TYPE_SIGNIFICAND_OFFSET (DOUBLE)
693
+ # define Z_DOUBLE_SIGNIFICAND_BITS Z_TYPE_SIGNIFICAND_BITS (DOUBLE)
694
+ # define Z_DOUBLE_SIGNIFICAND_DIGITS Z_TYPE_SIGNIFICAND_DIGITS (DOUBLE)
695
+ # define Z_DOUBLE_EXPONENT_OFFSET Z_TYPE_EXPONENT_OFFSET (DOUBLE)
696
+ # define Z_DOUBLE_EXPONENT_BITS Z_TYPE_EXPONENT_BITS (DOUBLE)
697
+ # define Z_DOUBLE_EXPONENT_RADIX Z_TYPE_EXPONENT_RADIX (DOUBLE)
698
+ # define Z_DOUBLE_EXPONENT_MINIMUM Z_TYPE_EXPONENT_MINIMUM (DOUBLE)
699
+ # define Z_DOUBLE_EXPONENT_MAXIMUM Z_TYPE_EXPONENT_MAXIMUM (DOUBLE)
700
+ # define Z_DOUBLE_EXPONENT_10_MINIMUM Z_TYPE_EXPONENT_10_MINIMUM(DOUBLE)
701
+ # define Z_DOUBLE_EXPONENT_10_MAXIMUM Z_TYPE_EXPONENT_10_MAXIMUM(DOUBLE)
702
+ # define Z_DOUBLE_SIGN_OFFSET Z_TYPE_SIGN_OFFSET (DOUBLE)
703
+ # define Z_DOUBLE_SIGN_BITS Z_TYPE_SIGN_BITS (DOUBLE)
704
+ # define Z_DOUBLE_EPSILON Z_TYPE_EPSILON (DOUBLE)
705
+ # define Z_DOUBLE_MINIMUM Z_TYPE_MINIMUM (DOUBLE)
706
+ # define Z_DOUBLE_MAXIMUM Z_TYPE_MAXIMUM (DOUBLE)
707
+ # define Z_DOUBLE_INFINITY Z_TYPE_INFINITY (DOUBLE)
708
+ # define Z_DOUBLE_NAN Z_TYPE_NAN (DOUBLE)
709
+
710
+ #endif
711
+
712
+ #if Z_LANGUAGE_HAS_TYPE(C, LDOUBLE) || Z_LANGUAGE_HAS_TYPE(CPP, LDOUBLE)
713
+
714
+ # define Z_LDOUBLE_FIXED_VALUE_TYPE Z_FLOATING_POINT_FIXED_VALUE_TYPE(LDOUBLE)
715
+
716
+ typedef long double zldouble;
717
+ typedef Z2DType(LDOUBLE) Z2DLDouble;
718
+ typedef Z3DType(LDOUBLE) Z3DLDouble;
719
+ typedef Z4DType(LDOUBLE) Z4DLDouble;
720
+ # define Z_LDOUBLE Z_SUFFIX_L
721
+ # define Z_LDOUBLE_VALUE_TYPE Z_VALUE_TYPE_LDOUBLE
722
+ # define Z_LDOUBLE_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (LDOUBLE)
723
+ # define Z_LDOUBLE_BITS Z_TYPE_BITS (LDOUBLE)
724
+ # define Z_LDOUBLE_SIZE Z_TYPE_SIZE (LDOUBLE)
725
+ # define Z_LDOUBLE_BIAS Z_TYPE_BIAS (LDOUBLE)
726
+ # define Z_LDOUBLE_DECIMAL_DIGITS Z_TYPE_DECIMAL_DIGITS (LDOUBLE)
727
+ # define Z_LDOUBLE_SIGNIFICAND_OFFSET Z_TYPE_SIGNIFICAND_OFFSET (LDOUBLE)
728
+ # define Z_LDOUBLE_SIGNIFICAND_BITS Z_TYPE_SIGNIFICAND_BITS (LDOUBLE)
729
+ # define Z_LDOUBLE_SIGNIFICAND_DIGITS Z_TYPE_SIGNIFICAND_DIGITS (LDOUBLE)
730
+ # define Z_LDOUBLE_EXPONENT_OFFSET Z_TYPE_EXPONENT_OFFSET (LDOUBLE)
731
+ # define Z_LDOUBLE_EXPONENT_BITS Z_TYPE_EXPONENT_BITS (LDOUBLE)
732
+ # define Z_LDOUBLE_EXPONENT_RADIX Z_TYPE_EXPONENT_RADIX (LDOUBLE)
733
+ # define Z_LDOUBLE_EXPONENT_MINIMUM Z_TYPE_EXPONENT_MINIMUM (LDOUBLE)
734
+ # define Z_LDOUBLE_EXPONENT_MAXIMUM Z_TYPE_EXPONENT_MAXIMUM (LDOUBLE)
735
+ # define Z_LDOUBLE_EXPONENT_10_MINIMUM Z_TYPE_EXPONENT_10_MINIMUM(LDOUBLE)
736
+ # define Z_LDOUBLE_EXPONENT_10_MAXIMUM Z_TYPE_EXPONENT_10_MAXIMUM(LDOUBLE)
737
+ # define Z_LDOUBLE_SIGN_OFFSET Z_TYPE_SIGN_OFFSET (LDOUBLE)
738
+ # define Z_LDOUBLE_SIGN_BITS Z_TYPE_SIGN_BITS (LDOUBLE)
739
+ # define Z_LDOUBLE_EPSILON Z_TYPE_EPSILON (LDOUBLE)
740
+ # define Z_LDOUBLE_MINIMUM Z_TYPE_MINIMUM (LDOUBLE)
741
+ # define Z_LDOUBLE_MAXIMUM Z_TYPE_MAXIMUM (LDOUBLE)
742
+ # define Z_LDOUBLE_INFINITY Z_TYPE_INFINITY (LDOUBLE)
743
+ # define Z_LDOUBLE_NAN Z_TYPE_NAN (LDOUBLE)
744
+
745
+ #endif
746
+
747
+ /* MARK: - Object size integral types */
748
+
749
+ #define Z_USIZE_BITS Z_DATA_MODEL_BITS(SIZE)
750
+
751
+ typedef ztype (USIZE) zusize;
752
+ typedef Z2DType(USIZE) Z2DUSize;
753
+ typedef Z3DType(USIZE) Z3DUSize;
754
+ typedef Z4DType(USIZE) Z4DUSize;
755
+ #define Z_USIZE Z_TYPE (USIZE)
756
+ #define Z_USIZE_VALUE_TYPE Z_TYPE_VALUE_TYPE (USIZE)
757
+ #define Z_USIZE_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(USIZE)
758
+ #define Z_USIZE_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (USIZE)
759
+ #define Z_USIZE_ENDIANNESS Z_TYPE_ENDIANNESS (USIZE)
760
+ #define Z_USIZE_SIZE Z_TYPE_SIZE (USIZE)
761
+ #define Z_USIZE_MINIMUM Z_TYPE_MINIMUM (USIZE)
762
+ #define Z_USIZE_MAXIMUM Z_TYPE_MAXIMUM (USIZE)
763
+
764
+ #define Z_SSIZE_BITS Z_DATA_MODEL_BITS(SIZE)
765
+
766
+ typedef ztype (SSIZE) zssize;
767
+ typedef Z2DType(SSIZE) Z2DSSize;
768
+ typedef Z3DType(SSIZE) Z3DSSize;
769
+ typedef Z4DType(SSIZE) Z4DSSize;
770
+ #define Z_SSIZE Z_TYPE (SSIZE)
771
+ #define Z_SSIZE_VALUE_TYPE Z_TYPE_VALUE_TYPE (SSIZE)
772
+ #define Z_SSIZE_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SSIZE)
773
+ #define Z_SSIZE_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SSIZE)
774
+ #define Z_SSIZE_ENDIANNESS Z_TYPE_ENDIANNESS (SSIZE)
775
+ #define Z_SSIZE_SIZE Z_TYPE_SIZE (SSIZE)
776
+ #define Z_SSIZE_MINIMUM Z_TYPE_MINIMUM (SSIZE)
777
+ #define Z_SSIZE_MAXIMUM Z_TYPE_MAXIMUM (SSIZE)
778
+
779
+ /* MARK: - Maximum size integral types */
780
+
781
+ #if defined(Z_UINT128)
782
+ # define Z_UINTMAX_BITS 128
783
+ #elif defined(Z_UINT64)
784
+ # define Z_UINTMAX_BITS 64
785
+ #elif defined(Z_ULLONG)
786
+ # define Z_UINTMAX_BITS Z_ULLONG_BITS
787
+ #else
788
+ # define Z_UINTMAX_BITS Z_ULONG_BITS
789
+ #endif
790
+
791
+ typedef ztype (UINTMAX) zuintmax;
792
+ typedef Z2DType(UINTMAX) Z2DUIntMax;
793
+ typedef Z3DType(UINTMAX) Z3DUIntMax;
794
+ typedef Z4DType(UINTMAX) Z4DUIntMax;
795
+ #define Z_UINTMAX Z_TYPE (UINTMAX)
796
+ #define Z_UINTMAX_VALUE_TYPE Z_TYPE_VALUE_TYPE (UINTMAX)
797
+ #define Z_UINTMAX_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(UINTMAX)
798
+ #define Z_UINTMAX_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (UINTMAX)
799
+ #define Z_UINTMAX_ENDIANNESS Z_TYPE_ENDIANNESS (UINTMAX)
800
+ #define Z_UINTMAX_SIZE Z_TYPE_SIZE (UINTMAX)
801
+ #define Z_UINTMAX_MINIMUM Z_TYPE_MINIMUM (UINTMAX)
802
+ #define Z_UINTMAX_MAXIMUM Z_TYPE_MAXIMUM (UINTMAX)
803
+
804
+ #if defined(Z_SINT128)
805
+ # define Z_SINTMAX_BITS 128
806
+ #elif defined(Z_SINT64)
807
+ # define Z_SINTMAX_BITS 64
808
+ #elif defined(Z_SLLONG)
809
+ # define Z_SINTMAX_BITS Z_SLLONG_BITS
810
+ #else
811
+ # define Z_SINTMAX_BITS Z_SLONG_BITS
812
+ #endif
813
+
814
+ typedef ztype (SINTMAX) zsintmax;
815
+ typedef Z2DType(SINTMAX) Z2DSIntMax;
816
+ typedef Z3DType(SINTMAX) Z3DSIntMax;
817
+ typedef Z4DType(SINTMAX) Z4DSIntMax;
818
+ #define Z_SINTMAX Z_TYPE (SINTMAX)
819
+ #define Z_SINTMAX_VALUE_TYPE Z_TYPE_VALUE_TYPE (SINTMAX)
820
+ #define Z_SINTMAX_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SINTMAX)
821
+ #define Z_SINTMAX_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SINTMAX)
822
+ #define Z_SINTMAX_ENDIANNESS Z_TYPE_ENDIANNESS (SINTMAX)
823
+ #define Z_SINTMAX_SIZE Z_TYPE_SIZE (SINTMAX)
824
+ #define Z_SINTMAX_MINIMUM Z_TYPE_MINIMUM (SINTMAX)
825
+ #define Z_SINTMAX_MAXIMUM Z_TYPE_MAXIMUM (SINTMAX)
826
+
827
+ #if Z_UINTMAX_BITS >= Z_SINTMAX_BITS
828
+
829
+ typedef zuintmax zintmax;
830
+ # define Z_INTMAX Z_UINTMAX
831
+ # define Z_INTMAX_VALUE_TYPE Z_UINTMAX_VALUE_TYPE
832
+ # define Z_INTMAX_FIXED_VALUE_TYPE Z_UINTMAX_FIXED_VALUE_TYPE
833
+ # define Z_INTMAX_VALUE_FORMAT Z_UINTMAX_VALUE_FORMAT
834
+ # define Z_INTMAX_ENDIANNESS Z_UINTMAX_ENDIANNESS
835
+ # define Z_INTMAX_BITS Z_UINTMAX_BITS
836
+ # define Z_INTMAX_SIZE Z_UINTMAX_SIZE
837
+
838
+ #else
839
+
840
+ typedef zsintmax zintmax;
841
+ # define Z_INTMAX Z_SINTMAX
842
+ # define Z_INTMAX_VALUE_TYPE Z_SINTMAX_VALUE_TYPE
843
+ # define Z_INTMAX_FIXED_VALUE_TYPE Z_SINTMAX_FIXED_VALUE_TYPE
844
+ # define Z_INTMAX_VALUE_FORMAT Z_SINTMAX_VALUE_FORMAT
845
+ # define Z_INTMAX_ENDIANNESS Z_SINTMAX_ENDIANNESS
846
+ # define Z_INTMAX_BITS Z_SINTMAX_BITS
847
+ # define Z_INTMAX_SIZE Z_SINTMAX_SIZE
848
+
849
+ #endif
850
+
851
+ /* MARK: - Pointer size integral types */
852
+
853
+ #define Z_POINTER_BITS Z_DATA_MODEL_BITS(POINTER)
854
+ #define Z_POINTER_SIZE (Z_UINTPTR_BITS / 8)
855
+
856
+ #define Z_UINTPTR_BITS Z_POINTER_BITS
857
+
858
+ typedef ztype (UINTPTR) zuintptr;
859
+ typedef Z2DType(UINTPTR) Z2DUIntPtr;
860
+ typedef Z3DType(UINTPTR) Z3DUIntPtr;
861
+ typedef Z4DType(UINTPTR) Z4DUIntPtr;
862
+ #define Z_UINTPTR Z_TYPE (UINTPTR)
863
+ #define Z_UINTPTR_VALUE_TYPE Z_TYPE_VALUE_TYPE (UINTPTR)
864
+ #define Z_UINTPTR_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(UINTPTR)
865
+ #define Z_UINTPTR_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (UINTPTR)
866
+ #define Z_UINTPTR_ENDIANNESS Z_TYPE_ENDIANNESS (UINTPTR)
867
+ #define Z_UINTPTR_SIZE Z_TYPE_SIZE (UINTPTR)
868
+ #define Z_UINTPTR_MINIMUM Z_TYPE_MINIMUM (UINTPTR)
869
+ #define Z_UINTPTR_MAXIMUM Z_TYPE_MAXIMUM (UINTPTR)
870
+
871
+ #define Z_SINTPTR_BITS Z_POINTER_BITS
872
+
873
+ typedef ztype (SINTPTR) zsintptr;
874
+ typedef Z2DType(SINTPTR) Z2DSIntPtr;
875
+ typedef Z3DType(SINTPTR) Z3DSIntPtr;
876
+ typedef Z4DType(SINTPTR) Z4DSIntPtr;
877
+ #define Z_SINTPTR Z_TYPE (SINTPTR)
878
+ #define Z_SINTPTR_VALUE_TYPE Z_TYPE_VALUE_TYPE (SINTPTR)
879
+ #define Z_SINTPTR_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SINTPTR)
880
+ #define Z_SINTPTR_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SINTPTR)
881
+ #define Z_SINTPTR_ENDIANNESS Z_TYPE_ENDIANNESS (SINTPTR)
882
+ #define Z_SINTPTR_SIZE Z_TYPE_SIZE (SINTPTR)
883
+ #define Z_SINTPTR_MINIMUM Z_TYPE_MINIMUM (SINTPTR)
884
+ #define Z_SINTPTR_MAXIMUM Z_TYPE_MAXIMUM (SINTPTR)
885
+
886
+ /* MARK: - Optimum maximum size integral types */
887
+
888
+ #if Z_CPU_BITS(TOP_INTEGER) >= 128 && defined(Z_UINT128)
889
+ # define Z_UINTTOP_BITS 128
890
+
891
+ #elif Z_CPU_BITS(TOP_INTEGER) >= 64 && defined(Z_UINT64)
892
+ # define Z_UINTTOP_BITS 64
893
+
894
+ #elif Z_CPU_BITS(TOP_INTEGER) == 32
895
+ # define Z_UINTTOP_BITS 32
896
+
897
+ #else
898
+ # define Z_UINTTOP_BITS 16
899
+ #endif
900
+
901
+ typedef ztype (UINTTOP) zuinttop;
902
+ typedef Z2DType(UINTTOP) Z2DUIntTop;
903
+ typedef Z3DType(UINTTOP) Z3DUIntTop;
904
+ typedef Z4DType(UINTTOP) Z4DUIntTop;
905
+ #define Z_UINTTOP Z_TYPE (UINTTOP)
906
+ #define Z_UINTTOP_VALUE_TYPE Z_TYPE_VALUE_TYPE (UINTTOP)
907
+ #define Z_UINTTOP_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(UINTTOP)
908
+ #define Z_UINTTOP_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (UINTTOP)
909
+ #define Z_UINTTOP_ENDIANNESS Z_TYPE_ENDIANNESS (UINTTOP)
910
+ #define Z_UINTTOP_SIZE Z_TYPE_SIZE (UINTTOP)
911
+ #define Z_UINTTOP_MINIMUM Z_TYPE_MINIMUM (UINTTOP)
912
+ #define Z_UINTTOP_MAXIMUM Z_TYPE_MAXIMUM (UINTTOP)
913
+
914
+ #if Z_CPU_BITS(TOP_INTEGER) >= 128 && defined(Z_SINT128)
915
+ # define Z_SINTTOP_BITS 128
916
+
917
+ #elif Z_CPU_BITS(TOP_INTEGER) >= 64 && defined(Z_SINT64)
918
+ # define Z_SINTTOP_BITS 64
919
+
920
+ #elif Z_CPU_BITS(TOP_INTEGER) == 32
921
+ # define Z_SINTTOP_BITS 32
922
+
923
+ #else
924
+ # define Z_SINTTOP_BITS 16
925
+ #endif
926
+
927
+ typedef ztype (SINTTOP) zsinttop;
928
+ typedef Z2DType(SINTTOP) Z2DSIntTop;
929
+ typedef Z3DType(SINTTOP) Z3DSIntTop;
930
+ typedef Z4DType(SINTTOP) Z4DSIntTop;
931
+ #define Z_SINTTOP Z_TYPE (SINTTOP)
932
+ #define Z_SINTTOP_VALUE_TYPE Z_TYPE_VALUE_TYPE (SINTTOP)
933
+ #define Z_SINTTOP_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(SINTTOP)
934
+ #define Z_SINTTOP_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (SINTTOP)
935
+ #define Z_SINTTOP_ENDIANNESS Z_TYPE_ENDIANNESS (SINTTOP)
936
+ #define Z_SINTTOP_SIZE Z_TYPE_SIZE (SINTTOP)
937
+ #define Z_SINTTOP_MINIMUM Z_TYPE_MINIMUM (SINTTOP)
938
+ #define Z_SINTTOP_MAXIMUM Z_TYPE_MAXIMUM (SINTTOP)
939
+
940
+ #if Z_UINTTOP_BITS >= Z_SINTTOP_BITS
941
+
942
+ typedef zuinttop zinttop;
943
+ # define Z_INTTOP Z_UINTTOP
944
+ # define Z_INTTOP_VALUE_TYPE Z_UINTTOP_VALUE_TYPE
945
+ # define Z_INTTOP_FIXED_VALUE_TYPE Z_UINTTOP_FIXED_VALUE_TYPE
946
+ # define Z_INTTOP_VALUE_FORMAT Z_UINTTOP_VALUE_FORMAT
947
+ # define Z_INTTOP_ENDIANNESS Z_UINTTOP_ENDIANNESS
948
+ # define Z_INTTOP_BITS Z_UINTTOP_BITS
949
+ # define Z_INTTOP_SIZE Z_UINTTOP_SIZE
950
+
951
+ #else
952
+
953
+ typedef zsinttop zinttop;
954
+ # define Z_INTTOP Z_SINTTOP
955
+ # define Z_INTTOP_VALUE_TYPE Z_SINTTOP_VALUE_TYPE
956
+ # define Z_INTTOP_FIXED_VALUE_TYPE Z_SINTTOP_FIXED_VALUE_TYPE
957
+ # define Z_INTTOP_VALUE_FORMAT Z_SINTTOP_VALUE_FORMAT
958
+ # define Z_INTTOP_ENDIANNESS Z_SINTTOP_ENDIANNESS
959
+ # define Z_INTTOP_BITS Z_SINTTOP_BITS
960
+ # define Z_INTTOP_SIZE Z_SINTTOP_SIZE
961
+
962
+ #endif
963
+
964
+ /* MARK: - Default types */
965
+
966
+ typedef zuint8 zboolean;
967
+ typedef Z2DUInt8 Z2DBoolean;
968
+ typedef Z3DUInt8 Z3DBoolean;
969
+ typedef Z4DUInt8 Z4DBoolean;
970
+ #define Z_BOOLEAN_VALUE_TYPE Z_UINT8_VALUE_TYPE
971
+ #define Z_BOOLEAN_FIXED_VALUE_TYPE Z_UINT8_FIXED_VALUE_TYPE
972
+ #define Z_BOOLEAN_VALUE_FORMAT Z_UINT8_VALUE_FORMAT
973
+ #define Z_BOOLEAN_BITS Z_UINT8_BITS
974
+ #define Z_BOOLEAN_SIZE Z_UINT8_SIZE
975
+
976
+ #if defined(Z_USE_NATURAL_UINT16)
977
+ # define Z_NATURAL_BITS 16
978
+
979
+ #elif defined(Z_USE_NATURAL_UINT32)
980
+ # define Z_NATURAL_BITS 32
981
+
982
+ #elif defined(Z_USE_NATURAL_UINT64) && defined(Z_UINT64)
983
+ # define Z_NATURAL_BITS 64
984
+
985
+ #elif defined(Z_USE_NATURAL_UINT128) && defined(Z_UINT128)
986
+ # define Z_NATURAL_BITS 128
987
+ #else
988
+ # define Z_NATURAL_BITS Z_ULONG_BITS
989
+ #endif
990
+
991
+ typedef ztype (NATURAL) znatural;
992
+ typedef Z2DType(NATURAL) Z2DNatural;
993
+ typedef Z3DType(NATURAL) Z3DNatural;
994
+ typedef Z4DType(NATURAL) Z4DNatural;
995
+ #define Z_NATURAL Z_TYPE (NATURAL)
996
+ #define Z_NATURAL_VALUE_TYPE Z_TYPE_VALUE_TYPE (NATURAL)
997
+ #define Z_NATURAL_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(NATURAL)
998
+ #define Z_NATURAL_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (NATURAL)
999
+ #define Z_NATURAL_ENDIANNESS Z_TYPE_ENDIANNESS (NATURAL)
1000
+ #define Z_NATURAL_SIZE Z_TYPE_SIZE (NATURAL)
1001
+ #define Z_NATURAL_MINIMUM Z_TYPE_MINIMUM (NATURAL)
1002
+ #define Z_NATURAL_MAXIMUM Z_TYPE_MAXIMUM (NATURAL)
1003
+
1004
+ #if defined(Z_USE_INTEGER_SINT16)
1005
+ # define Z_INTEGER_BITS 16
1006
+
1007
+ #elif defined(Z_USE_INTEGER_SINT32)
1008
+ # define Z_INTEGER_BITS 32
1009
+
1010
+ #elif defined(Z_USE_INTEGER_SINT64) && defined(Z_SINT64)
1011
+ # define Z_INTEGER_BITS 64
1012
+
1013
+ #elif defined(Z_USE_INTEGER_SINT128) && defined(Z_SINT128)
1014
+ # define Z_INTEGER_BITS 128
1015
+ #else
1016
+ # define Z_INTEGER_BITS Z_SLONG_BITS
1017
+ #endif
1018
+
1019
+ typedef ztype (INTEGER) zinteger;
1020
+ typedef Z2DType(INTEGER) Z2DInteger;
1021
+ typedef Z3DType(INTEGER) Z3DInteger;
1022
+ typedef Z4DType(INTEGER) Z4DInteger;
1023
+ #define Z_INTEGER Z_TYPE (INTEGER)
1024
+ #define Z_INTEGER_VALUE_TYPE Z_TYPE_VALUE_TYPE (INTEGER)
1025
+ #define Z_INTEGER_FIXED_VALUE_TYPE Z_TYPE_FIXED_VALUE_TYPE(INTEGER)
1026
+ #define Z_INTEGER_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (INTEGER)
1027
+ #define Z_INTEGER_ENDIANNESS Z_TYPE_ENDIANNESS (INTEGER)
1028
+ #define Z_INTEGER_SIZE Z_TYPE_SIZE (INTEGER)
1029
+ #define Z_INTEGER_MINIMUM Z_TYPE_MINIMUM (INTEGER)
1030
+ #define Z_INTEGER_MAXIMUM Z_TYPE_MAXIMUM (INTEGER)
1031
+
1032
+ #if defined(Z_USE_REAL_FLOAT16) && defined(Z_FLOAT16)
1033
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT16
1034
+
1035
+ #elif defined(Z_USE_REAL_FLOAT32) && defined(Z_FLOAT32)
1036
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT32
1037
+
1038
+ #elif defined(Z_USE_REAL_FLOAT64) && defined(Z_FLOAT64)
1039
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT64
1040
+
1041
+ #elif defined(Z_USE_REAL_FLOAT128) && defined(Z_FLOAT128)
1042
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT128
1043
+
1044
+ #elif defined(Z_USE_REAL_FLOAT80_X87) && defined(Z_FLOAT80_X87)
1045
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT80_X87
1046
+
1047
+ #elif defined(Z_USE_REAL_FLOAT96_X87) && defined(Z_FLOAT96_X87)
1048
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT96_X87
1049
+
1050
+ #elif defined(Z_USE_REAL_FLOAT128_X87) && defined(Z_FLOAT128_X87)
1051
+ # define Z_REAL_FIXED_VALUE_TYPE Z_VALUE_TYPE_FLOAT128_X87
1052
+
1053
+ #elif defined(Z_USE_REAL_FLOAT) && defined(Z_FLOAT)
1054
+ # define Z_REAL_FIXED_VALUE_TYPE Z_FLOAT_FIXED_VALUE_TYPE
1055
+
1056
+ #elif defined(Z_USE_REAL_LDOUBLE) && defined(Z_LDOUBLE)
1057
+ # define Z_REAL_FIXED_VALUE_TYPE Z_DOUBLE_FIXED_VALUE_TYPE
1058
+
1059
+ #elif defined(Z_DOUBLE)
1060
+ # define Z_REAL_FIXED_VALUE_TYPE Z_DOUBLE_FIXED_VALUE_TYPE
1061
+ #endif
1062
+
1063
+ #ifdef Z_REAL_FIXED_VALUE_TYPE
1064
+
1065
+ typedef ztype (REAL) zreal;
1066
+ typedef Z2DType(REAL) Z2DReal;
1067
+ typedef Z3DType(REAL) Z3DReal;
1068
+ typedef Z4DType(REAL) Z4DReal;
1069
+ typedef Z2DReal Z2D;
1070
+ typedef Z3DReal Z3D;
1071
+ typedef Z4DReal Z4D;
1072
+ # define Z_REAL Z_TYPE (REAL)
1073
+ # define Z_REAL_VALUE_TYPE Z_TYPE_VALUE_TYPE (REAL)
1074
+ # define Z_REAL_VALUE_FORMAT Z_TYPE_VALUE_FORMAT (REAL)
1075
+ # define Z_REAL_BITS Z_TYPE_BITS (REAL)
1076
+ # define Z_REAL_SIZE Z_TYPE_SIZE (REAL)
1077
+ # define Z_REAL_BIAS Z_TYPE_BIAS (REAL)
1078
+ # define Z_REAL_DECIMAL_DIGITS Z_TYPE_DECIMAL_DIGITS (REAL)
1079
+ # define Z_REAL_SIGNIFICAND_OFFSET Z_TYPE_SIGNIFICAND_OFFSET (REAL)
1080
+ # define Z_REAL_SIGNIFICAND_BITS Z_TYPE_SIGNIFICAND_BITS (REAL)
1081
+ # define Z_REAL_SIGNIFICAND_DIGITS Z_TYPE_SIGNIFICAND_DIGITS (REAL)
1082
+ # define Z_REAL_EXPONENT_OFFSET Z_TYPE_EXPONENT_OFFSET (REAL)
1083
+ # define Z_REAL_EXPONENT_BITS Z_TYPE_EXPONENT_BITS (REAL)
1084
+ # define Z_REAL_EXPONENT_RADIX Z_TYPE_EXPONENT_RADIX (REAL)
1085
+ # define Z_REAL_EXPONENT_MINIMUM Z_TYPE_EXPONENT_MINIMUM (REAL)
1086
+ # define Z_REAL_EXPONENT_MAXIMUM Z_TYPE_EXPONENT_MAXIMUM (REAL)
1087
+ # define Z_REAL_EXPONENT_10_MINIMUM Z_TYPE_EXPONENT_10_MINIMUM(REAL)
1088
+ # define Z_REAL_EXPONENT_10_MAXIMUM Z_TYPE_EXPONENT_10_MAXIMUM(REAL)
1089
+ # define Z_REAL_SIGN_OFFSET Z_TYPE_SIGN_OFFSET (REAL)
1090
+ # define Z_REAL_SIGN_BITS Z_TYPE_SIGN_BITS (REAL)
1091
+ # define Z_REAL_EPSILON Z_TYPE_EPSILON (REAL)
1092
+ # define Z_REAL_MINIMUM Z_TYPE_MINIMUM (REAL)
1093
+ # define Z_REAL_MAXIMUM Z_TYPE_MAXIMUM (REAL)
1094
+ # define Z_REAL_INFINITY Z_TYPE_INFINITY (REAL)
1095
+ # define Z_REAL_NAN Z_TYPE_NAN (REAL)
1096
+
1097
+ #endif
1098
+
1099
+ /* MARK: - Status type */
1100
+
1101
+ typedef zsint ZStatus;
1102
+
1103
+ /* MARK: - Range types */
1104
+
1105
+ typedef struct {zuint8 index, size;} ZRangeUInt8;
1106
+ typedef struct {zuint16 index, size;} ZRangeUInt16;
1107
+ typedef struct {zuint32 index, size;} ZRangeUInt32;
1108
+
1109
+ #ifdef Z_UINT64
1110
+ typedef struct {zuint64 index, size;} ZRangeUInt64;
1111
+ #endif
1112
+
1113
+ #ifdef Z_UINT128
1114
+ typedef struct {zuint128 index, size;} ZRangeUInt128;
1115
+ #endif
1116
+
1117
+ #define ZRangeType(TYPE) Z_APPEND_##TYPE##_FixedType(ZRange)
1118
+
1119
+ typedef ZRangeType(UCHAR ) ZRangeUChar;
1120
+ typedef ZRangeType(USHORT) ZRangeUShort;
1121
+ typedef ZRangeType(UINT ) ZRangeUInt;
1122
+ typedef ZRangeType(ULONG ) ZRangeULong;
1123
+
1124
+ #ifdef Z_ULLONG
1125
+ typedef ZRangeType(ULLONG) ZRangeULLong;
1126
+ #else
1127
+ typedef ZRangeULong ZRangeULLong;
1128
+ #endif
1129
+
1130
+ typedef ZRangeType(USIZE ) ZRangeUSize;
1131
+ typedef ZRangeType(UINTMAX) ZRangeUIntMax;
1132
+ typedef ZRangeType(UINTPTR) ZRangeUIntPtr;
1133
+ typedef ZRangeType(UINTTOP) ZRangeUIntTop;
1134
+ typedef ZRangeType(NATURAL) ZRangeNatural;
1135
+ typedef ZRangeUSize ZRange;
1136
+
1137
+ /* MARK: - Value component access types */
1138
+
1139
+ Z_DEFINE_STRICT_UNION (
1140
+ zuint8 value_uint8;
1141
+ zsint8 value_sint8;
1142
+ ) Z8Bit;
1143
+
1144
+ Z_DEFINE_STRICT_UNION_BEGIN
1145
+ zuint16 value_uint16;
1146
+ zsint16 value_sint16;
1147
+ zuint8 array_uint8[2];
1148
+ zsint8 array_sint8[2];
1149
+
1150
+ struct {Z_ENDIANIZED_MEMBERS(16, 2) (
1151
+ zuint8 index1,
1152
+ zuint8 index0
1153
+ )} values_uint8;
1154
+
1155
+ struct {Z_ENDIANIZED_MEMBERS(16, 2) (
1156
+ zsint8 index1,
1157
+ zsint8 index0
1158
+ )} values_sint8;
1159
+ Z_DEFINE_STRICT_UNION_END Z16Bit;
1160
+
1161
+ Z_DEFINE_STRICT_UNION_BEGIN
1162
+ zuint32 value_uint32;
1163
+ zsint32 value_sint32;
1164
+ zuint16 array_uint16[2];
1165
+ zsint16 array_sint16[2];
1166
+ zuint8 array_uint8 [4];
1167
+ zsint8 array_sint8 [4];
1168
+
1169
+ struct {Z_ENDIANIZED_MEMBERS(32, 2) (
1170
+ zuint16 index1,
1171
+ zuint16 index0
1172
+ )} values_uint16;
1173
+
1174
+ struct {Z_ENDIANIZED_MEMBERS(32, 2) (
1175
+ zsint16 index1,
1176
+ zsint16 index0
1177
+ )} values_sint16;
1178
+
1179
+ struct {Z_ENDIANIZED_MEMBERS(32, 4) (
1180
+ zuint8 index3,
1181
+ zuint8 index2,
1182
+ zuint8 index1,
1183
+ zuint8 index0
1184
+ )} values_uint8;
1185
+
1186
+ struct {Z_ENDIANIZED_MEMBERS(32, 4) (
1187
+ zsint8 index3,
1188
+ zsint8 index2,
1189
+ zsint8 index1,
1190
+ zsint8 index0
1191
+ )} values_sint8;
1192
+ Z_DEFINE_STRICT_UNION_END Z32Bit;
1193
+
1194
+ Z_DEFINE_STRICT_UNION_BEGIN
1195
+ zuint32 array_uint32[2];
1196
+ zsint32 array_sint32[2];
1197
+ zuint16 array_uint16[4];
1198
+ zsint16 array_sint16[4];
1199
+ zuint8 array_uint8 [8];
1200
+ zsint8 array_sint8 [8];
1201
+
1202
+ struct {Z_ENDIANIZED_MEMBERS(64, 2) (
1203
+ zuint32 index1,
1204
+ zuint32 index0
1205
+ )} values_uint32;
1206
+
1207
+ struct {Z_ENDIANIZED_MEMBERS(64, 2) (
1208
+ zsint32 index1,
1209
+ zsint32 index0
1210
+ )} values_sint32;
1211
+
1212
+ struct {Z_ENDIANIZED_MEMBERS(64, 4) (
1213
+ zuint16 index3,
1214
+ zuint16 index2,
1215
+ zuint16 index1,
1216
+ zuint16 index0
1217
+ )} values_uint16;
1218
+
1219
+ struct {Z_ENDIANIZED_MEMBERS(64, 4) (
1220
+ zsint16 index3,
1221
+ zsint16 index2,
1222
+ zsint16 index1,
1223
+ zsint16 index0
1224
+ )} values_sint16;
1225
+
1226
+ struct {Z_ENDIANIZED_MEMBERS(64, 8) (
1227
+ zuint8 index7,
1228
+ zuint8 index6,
1229
+ zuint8 index5,
1230
+ zuint8 index4,
1231
+ zuint8 index3,
1232
+ zuint8 index2,
1233
+ zuint8 index1,
1234
+ zuint8 index0
1235
+ )} values_uint8;
1236
+
1237
+ struct {Z_ENDIANIZED_MEMBERS(64, 8) (
1238
+ zsint8 index7,
1239
+ zsint8 index6,
1240
+ zsint8 index5,
1241
+ zsint8 index4,
1242
+ zsint8 index3,
1243
+ zsint8 index2,
1244
+ zsint8 index1,
1245
+ zsint8 index0
1246
+ )} values_sint8;
1247
+
1248
+ # ifdef Z_UINT64
1249
+ zuint64 value_uint64;
1250
+ # endif
1251
+
1252
+ # ifdef Z_SINT64
1253
+ zsint64 value_sint64;
1254
+ # endif
1255
+ Z_DEFINE_STRICT_UNION_END Z64Bit;
1256
+
1257
+ Z_DEFINE_STRICT_UNION_BEGIN
1258
+ zuint32 array_uint32[ 4];
1259
+ zsint32 array_sint32[ 4];
1260
+ zuint16 array_uint16[ 8];
1261
+ zsint16 array_sint16[ 8];
1262
+ zuint8 array_uint8 [16];
1263
+ zsint8 array_sint8 [16];
1264
+
1265
+ struct {Z_ENDIANIZED_MEMBERS(128, 4) (
1266
+ zuint32 index3,
1267
+ zuint32 index2,
1268
+ zuint32 index1,
1269
+ zuint32 index0
1270
+ )} values_uint32;
1271
+
1272
+ struct {Z_ENDIANIZED_MEMBERS(128, 4) (
1273
+ zsint32 index3,
1274
+ zsint32 index2,
1275
+ zsint32 index1,
1276
+ zsint32 index0
1277
+ )} values_sint32;
1278
+
1279
+ struct {Z_ENDIANIZED_MEMBERS(128, 8) (
1280
+ zuint16 index7,
1281
+ zuint16 index6,
1282
+ zuint16 index5,
1283
+ zuint16 index4,
1284
+ zuint16 index3,
1285
+ zuint16 index2,
1286
+ zuint16 index1,
1287
+ zuint16 index0
1288
+ )} values_uint16;
1289
+
1290
+ struct {Z_ENDIANIZED_MEMBERS(128, 8) (
1291
+ zsint16 index7,
1292
+ zsint16 index6,
1293
+ zsint16 index5,
1294
+ zsint16 index4,
1295
+ zsint16 index3,
1296
+ zsint16 index2,
1297
+ zsint16 index1,
1298
+ zsint16 index0
1299
+ )} values_sint16;
1300
+
1301
+ struct {Z_ENDIANIZED_MEMBERS(128, 16) (
1302
+ zuint8 index15,
1303
+ zuint8 index14,
1304
+ zuint8 index13,
1305
+ zuint8 index12,
1306
+ zuint8 index11,
1307
+ zuint8 index10,
1308
+ zuint8 index09,
1309
+ zuint8 index08,
1310
+ zuint8 index07,
1311
+ zuint8 index06,
1312
+ zuint8 index05,
1313
+ zuint8 index04,
1314
+ zuint8 index03,
1315
+ zuint8 index02,
1316
+ zuint8 index01,
1317
+ zuint8 index00
1318
+ )} values_uint8;
1319
+
1320
+ struct {Z_ENDIANIZED_MEMBERS(128, 16) (
1321
+ zsint8 index15,
1322
+ zsint8 index14,
1323
+ zsint8 index13,
1324
+ zsint8 index12,
1325
+ zsint8 index11,
1326
+ zsint8 index10,
1327
+ zsint8 index09,
1328
+ zsint8 index08,
1329
+ zsint8 index07,
1330
+ zsint8 index06,
1331
+ zsint8 index05,
1332
+ zsint8 index04,
1333
+ zsint8 index03,
1334
+ zsint8 index02,
1335
+ zsint8 index01,
1336
+ zsint8 index00
1337
+ )} values_sint8;
1338
+
1339
+ # ifdef Z_UINT128
1340
+ zuint128 value_uint128;
1341
+ # endif
1342
+
1343
+ # ifdef Z_SINT128
1344
+ zsint128 value_sint128;
1345
+ # endif
1346
+
1347
+ # ifdef Z_UINT64
1348
+ zuint64 array_uint64[2];
1349
+
1350
+ struct {Z_ENDIANIZED_MEMBERS(128, 2) (
1351
+ zuint64 index1,
1352
+ zuint64 index0
1353
+ )} values_uint64;
1354
+ # endif
1355
+
1356
+ # ifdef Z_SINT64
1357
+ zsint64 array_sint64[2];
1358
+
1359
+ struct {Z_ENDIANIZED_MEMBERS(128, 2) (
1360
+ zsint64 index1,
1361
+ zsint64 index0
1362
+ )} values_sint64;
1363
+ # endif
1364
+ Z_DEFINE_STRICT_UNION_END Z128Bit;
1365
+
1366
+ /* MARK: - Pointer type-casting type */
1367
+
1368
+ Z_DEFINE_STRICT_UNION_BEGIN
1369
+ void (* pointer_function)(void);
1370
+
1371
+ zuint8* pointer_uint8;
1372
+ Z2DUInt8* pointer_2d_uint8;
1373
+ Z3DUInt8* pointer_3d_uint8;
1374
+ Z4DUInt8* pointer_4d_uint8;
1375
+ ZRangeUInt8* pointer_range_uint8;
1376
+
1377
+ zsint8* pointer_sint8;
1378
+ Z2DSInt8* pointer_2d_sint8;
1379
+ Z3DSInt8* pointer_3d_sint8;
1380
+ Z4DSInt8* pointer_4d_sint8;
1381
+
1382
+ zuint16* pointer_uint16;
1383
+ Z2DUInt16* pointer_2d_uint16;
1384
+ Z3DUInt16* pointer_3d_uint16;
1385
+ Z4DUInt16* pointer_4d_uint16;
1386
+ ZRangeUInt16* pointer_range_uint16;
1387
+
1388
+ zsint16* pointer_sint16;
1389
+ Z2DSInt16* pointer_2d_sint16;
1390
+ Z3DSInt16* pointer_3d_sint16;
1391
+ Z4DSInt16* pointer_4d_sint16;
1392
+
1393
+ zuint32* pointer_uint32;
1394
+ Z2DUInt32* pointer_2d_uint32;
1395
+ Z3DUInt32* pointer_3d_uint32;
1396
+ Z4DUInt32* pointer_4d_uint32;
1397
+ ZRangeUInt32* pointer_range_uint32;
1398
+
1399
+ zsint32* pointer_sint32;
1400
+ Z2DSInt32* pointer_2d_sint32;
1401
+ Z3DSInt32* pointer_3d_sint32;
1402
+ Z4DSInt32* pointer_4d_sint32;
1403
+
1404
+ # ifdef Z_UINT64
1405
+ zuint64* pointer_uint64;
1406
+ Z2DUInt64* pointer_2d_uint64;
1407
+ Z3DUInt64* pointer_3d_uint64;
1408
+ Z4DUInt64* pointer_4d_uint64;
1409
+ ZRangeUInt64* pointer_range_uint64;
1410
+ # endif
1411
+
1412
+ # ifdef Z_SINT64
1413
+ zsint64* pointer_sint64;
1414
+ Z2DSInt64* pointer_2d_sint64;
1415
+ Z3DSInt64* pointer_3d_sint64;
1416
+ Z4DSInt64* pointer_4d_sint64;
1417
+ # endif
1418
+
1419
+ # ifdef Z_UINT128
1420
+ zuint128* pointer_uint128;
1421
+ Z2DUInt128* pointer_2d_uint128;
1422
+ Z3DUInt128* pointer_3d_uint128;
1423
+ Z4DUInt128* pointer_4d_uint128;
1424
+ ZRangeUInt128* pointer_range_uint128;
1425
+ # endif
1426
+
1427
+ # ifdef Z_SINT128
1428
+ zsint128* pointer_sint128;
1429
+ Z2DSInt128* pointer_2d_sint128;
1430
+ Z3DSInt128* pointer_3d_sint128;
1431
+ Z4DSInt128* pointer_4d_sint128;
1432
+ # endif
1433
+
1434
+ # ifdef Z_FLOAT16
1435
+ zfloat16* pointer_float16;
1436
+ Z2DFloat16* pointer_2d_float16;
1437
+ Z3DFloat16* pointer_3d_float16;
1438
+ Z4DFloat16* pointer_4d_float16;
1439
+ # endif
1440
+
1441
+ # ifdef Z_FLOAT32
1442
+ zfloat32* pointer_float32;
1443
+ Z2DFloat32* pointer_2d_float32;
1444
+ Z3DFloat32* pointer_3d_float32;
1445
+ Z4DFloat32* pointer_4d_float32;
1446
+ # endif
1447
+
1448
+ # ifdef Z_FLOAT64
1449
+ zfloat64* pointer_float64;
1450
+ Z2DFloat64* pointer_2d_float64;
1451
+ Z3DFloat64* pointer_3d_float64;
1452
+ Z4DFloat64* pointer_4d_float64;
1453
+ # endif
1454
+
1455
+ # ifdef Z_FLOAT128
1456
+ zfloat128* pointer_float128;
1457
+ Z2DFloat128* pointer_2d_float128;
1458
+ Z3DFloat128* pointer_3d_float128;
1459
+ Z4DFloat128* pointer_4d_float128;
1460
+ # endif
1461
+
1462
+ # ifdef Z_FLOAT80_X87
1463
+ zfloat80_x87* pointer_float80_x87;
1464
+ Z2DFloat80_x87* pointer_2d_float80_x87;
1465
+ Z3DFloat80_x87* pointer_3d_float80_x87;
1466
+ Z4DFloat80_x87* pointer_4d_float80_x87;
1467
+ # endif
1468
+
1469
+ # ifdef Z_FLOAT96_X87
1470
+ zfloat96_x87* pointer_float96_x87;
1471
+ Z2DFloat96_x87* pointer_2d_float96_x87;
1472
+ Z3DFloat96_x87* pointer_3d_float96_x87;
1473
+ Z4DFloat96_x87* pointer_4d_float96_x87;
1474
+ # endif
1475
+
1476
+ # ifdef Z_FLOAT128_X87
1477
+ zfloat128_x87* pointer_float128_x87;
1478
+ Z2DFloat128_x87* pointer_2d_float128_x87;
1479
+ Z3DFloat128_x87* pointer_3d_float128_x87;
1480
+ Z4DFloat128_x87* pointer_4d_float128_x87;
1481
+ # endif
1482
+
1483
+ zchar* pointer_char;
1484
+
1485
+ zuchar* pointer_uchar;
1486
+ Z2DUChar* pointer_2d_uchar;
1487
+ Z3DUChar* pointer_3d_uchar;
1488
+ Z4DUChar* pointer_4d_uchar;
1489
+ ZRangeUChar* pointer_range_uchar;
1490
+
1491
+ zschar* pointer_schar;
1492
+ Z2DSChar* pointer_2d_schar;
1493
+ Z3DSChar* pointer_3d_schar;
1494
+ Z4DSChar* pointer_4d_schar;
1495
+
1496
+ zushort* pointer_ushort;
1497
+ Z2DUShort* pointer_2d_ushort;
1498
+ Z3DUShort* pointer_3d_ushort;
1499
+ Z4DUShort* pointer_4d_ushort;
1500
+ ZRangeUShort* pointer_range_ushort;
1501
+
1502
+ zsshort* pointer_sshort;
1503
+ Z2DSShort* pointer_2d_sshort;
1504
+ Z3DSShort* pointer_3d_sshort;
1505
+ Z4DSShort* pointer_4d_sshort;
1506
+
1507
+ zuint* pointer_uint;
1508
+ Z2DUInt* pointer_2d_uint;
1509
+ Z3DUInt* pointer_3d_uint;
1510
+ Z4DUInt* pointer_4d_uint;
1511
+ ZRangeUInt* pointer_range_uint;
1512
+
1513
+ zsint* pointer_sint;
1514
+ Z2DSInt* pointer_2d_sint;
1515
+ Z3DSInt* pointer_3d_sint;
1516
+ Z4DSInt* pointer_4d_sint;
1517
+
1518
+ zulong* pointer_ulong;
1519
+ Z2DULong* pointer_2d_ulong;
1520
+ Z3DULong* pointer_3d_ulong;
1521
+ Z4DULong* pointer_4d_ulong;
1522
+ ZRangeULong* pointer_range_ulong;
1523
+
1524
+ zslong* pointer_slong;
1525
+ Z2DSLong* pointer_2d_slong;
1526
+ Z3DSLong* pointer_3d_slong;
1527
+ Z4DSLong* pointer_4d_slong;
1528
+
1529
+ # ifdef Z_ULLONG
1530
+ zullong* pointer_ullong;
1531
+ Z2DULLong* pointer_2d_ullong;
1532
+ Z3DULLong* pointer_3d_ullong;
1533
+ Z4DULLong* pointer_4d_ullong;
1534
+ ZRangeULLong* pointer_range_ullong;
1535
+ # endif
1536
+
1537
+ # ifdef Z_SLLONG
1538
+ zsllong* pointer_sllong;
1539
+ Z2DSLLong* pointer_2d_sllong;
1540
+ Z3DSLLong* pointer_3d_sllong;
1541
+ Z4DSLLong* pointer_4d_sllong;
1542
+ # endif
1543
+
1544
+ # ifdef Z_FLOAT
1545
+ zfloat* pointer_float;
1546
+ Z2DFloat* pointer_2d_float;
1547
+ Z3DFloat* pointer_3d_float;
1548
+ Z4DFloat* pointer_4d_float;
1549
+ # endif
1550
+
1551
+ # ifdef Z_DOUBLE
1552
+ zdouble* pointer_double;
1553
+ Z2DDouble* pointer_2d_double;
1554
+ Z3DDouble* pointer_3d_double;
1555
+ Z4DDouble* pointer_4d_double;
1556
+ # endif
1557
+
1558
+ # ifdef Z_LDOUBLE
1559
+ zldouble* pointer_ldouble;
1560
+ Z2DLDouble* pointer_2d_ldouble;
1561
+ Z3DLDouble* pointer_3d_ldouble;
1562
+ Z4DLDouble* pointer_4d_ldouble;
1563
+ # endif
1564
+
1565
+ zusize* pointer_usize;
1566
+ Z2DUSize* pointer_2d_usize;
1567
+ Z3DUSize* pointer_3d_usize;
1568
+ Z4DUSize* pointer_4d_usize;
1569
+ ZRangeUSize* pointer_range_usize;
1570
+
1571
+ zssize* pointer_ssize;
1572
+ Z2DSSize* pointer_2d_ssize;
1573
+ Z3DSSize* pointer_3d_ssize;
1574
+ Z4DSSize* pointer_4d_ssize;
1575
+
1576
+ zuintmax* pointer_uintmax;
1577
+ Z2DUIntMax* pointer_2d_uintmax;
1578
+ Z3DUIntMax* pointer_3d_uintmax;
1579
+ Z4DUIntMax* pointer_4d_uintmax;
1580
+ ZRangeUIntMax* pointer_range_uintmax;
1581
+
1582
+ zsintmax* pointer_sintmax;
1583
+ Z2DSIntMax* pointer_2d_sintmax;
1584
+ Z3DSIntMax* pointer_3d_sintmax;
1585
+ Z4DSIntMax* pointer_4d_sintmax;
1586
+
1587
+ zintmax* pointer_intmax;
1588
+
1589
+ zuintptr* pointer_uintptr;
1590
+ Z2DUIntPtr* pointer_2d_uintptr;
1591
+ Z3DUIntPtr* pointer_3d_uintptr;
1592
+ Z4DUIntPtr* pointer_4d_uintptr;
1593
+ ZRangeUIntPtr* pointer_range_uintptr;
1594
+
1595
+ zsintptr* pointer_sintptr;
1596
+ Z2DSIntPtr* pointer_2d_sintptr;
1597
+ Z3DSIntPtr* pointer_3d_sintptr;
1598
+ Z4DSIntPtr* pointer_4d_sintptr;
1599
+
1600
+ zuinttop* pointer_uinttop;
1601
+ Z2DUIntTop* pointer_2d_uinttop;
1602
+ Z3DUIntTop* pointer_3d_uinttop;
1603
+ Z4DUIntTop* pointer_4d_uinttop;
1604
+ ZRangeUIntTop* pointer_range_uinttop;
1605
+
1606
+ zsinttop* pointer_sinttop;
1607
+ Z2DSIntTop* pointer_2d_sinttop;
1608
+ Z3DSIntTop* pointer_3d_sinttop;
1609
+ Z4DSIntTop* pointer_4d_sinttop;
1610
+
1611
+ zinttop* pointer_inttop;
1612
+
1613
+ zboolean* pointer_boolean;
1614
+ Z2DBoolean* pointer_2d_boolean;
1615
+ Z3DBoolean* pointer_3d_boolean;
1616
+ Z4DBoolean* pointer_4d_boolean;
1617
+
1618
+ znatural* pointer_natural;
1619
+ Z2DNatural* pointer_2d_natural;
1620
+ Z3DNatural* pointer_3d_natural;
1621
+ Z4DNatural* pointer_4d_natural;
1622
+ ZRangeNatural* pointer_range_natural;
1623
+
1624
+ zinteger* pointer_integer;
1625
+ Z2DInteger* pointer_2d_integer;
1626
+ Z3DInteger* pointer_3d_integer;
1627
+ Z4DInteger* pointer_4d_integer;
1628
+
1629
+ # ifdef Z_REAL
1630
+ zreal* pointer_real;
1631
+ Z2DReal* pointer_2d_real;
1632
+ Z3DReal* pointer_3d_real;
1633
+ Z4DReal* pointer_4d_real;
1634
+ # endif
1635
+
1636
+ ZStatus* pointer_status;
1637
+
1638
+ ZRange* pointer_range;
1639
+
1640
+ Z8Bit* pointer_8bit;
1641
+ Z16Bit* pointer_16bit;
1642
+ Z32Bit* pointer_32bit;
1643
+ Z64Bit* pointer_64bit;
1644
+ Z128Bit* pointer_128bit;
1645
+
1646
+ void* pointer;
1647
+ zuintptr value_uintptr;
1648
+ zsintptr value_sintptr;
1649
+
1650
+ # ifdef Z_EXTENSION_POINTER
1651
+ Z_EXTENSION_POINTER
1652
+ # endif
1653
+ Z_DEFINE_STRICT_UNION_END ZPointer;
1654
+
1655
+ #endif /* _Z_types_base_H_ */