|
| 1 | +------------------------------------------------------------------------------ |
| 2 | +-- -- |
| 3 | +-- GNATcoverage Instrumentation Runtime -- |
| 4 | +-- -- |
| 5 | +-- Copyright (C) 2021-2023, AdaCore -- |
| 6 | +-- -- |
| 7 | +-- GNATcoverage is free software; you can redistribute it and/or modify it -- |
| 8 | +-- under terms of the GNU General Public License as published by the Free -- |
| 9 | +-- Software Foundation; either version 3, or (at your option) any later -- |
| 10 | +-- version. This software is distributed in the hope that it will be useful -- |
| 11 | +-- but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHAN- -- |
| 12 | +-- TABILITY or FITNESS FOR A PARTICULAR PURPOSE. -- |
| 13 | +-- -- |
| 14 | +-- As a special exception under Section 7 of GPL version 3, you are granted -- |
| 15 | +-- additional permissions described in the GCC Runtime Library Exception, -- |
| 16 | +-- version 3.1, as published by the Free Software Foundation. -- |
| 17 | +-- -- |
| 18 | +-- You should have received a copy of the GNU General Public License and -- |
| 19 | +-- a copy of the GCC Runtime Library Exception along with this program; -- |
| 20 | +-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- |
| 21 | +-- <http://www.gnu.org/licenses/>. -- |
| 22 | +-- -- |
| 23 | +------------------------------------------------------------------------------ |
| 24 | + |
| 25 | +-- Basic types to use in source trace buffers. We try to avoid using types |
| 26 | +-- from Interfaces and Interfaces.C, and in general to minimize the set of |
| 27 | +-- dependencies of GNATcov_RTS on the Ada runtime, so that we can compute code |
| 28 | +-- coverage for these runtime units. |
| 29 | +-- |
| 30 | +-- This unit needs to be compilable with Ada 95 compilers |
| 31 | + |
| 32 | +with System; |
| 33 | + |
| 34 | +package GNATcov_RTS.Types is |
| 35 | + |
| 36 | + pragma Pure; |
| 37 | + |
| 38 | + type Unsigned_8 is mod 2 ** 8; |
| 39 | + type Unsigned_64 is mod 2 ** 64; |
| 40 | + |
| 41 | + -- We assume here that Integer (Ada) is a correct mapping for int (C) |
| 42 | + |
| 43 | + type int is new Integer; |
| 44 | + type unsigned is mod 2 ** int'Size; |
| 45 | + type size_t is mod System.Memory_Size; |
| 46 | + |
| 47 | +end GNATcov_RTS.Types; |
0 commit comments