1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
5 -- V X L I N K . B I N D --
9 -- Copyright (C) 2018, AdaCore --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License --
17 -- for more details. You should have received a copy of the GNU General --
18 -- Public License distributed with GNAT; see file COPYING3. If not, go to --
19 -- http://www.gnu.org/licenses for a complete copy of the license. --
21 -- GNAT was originally developed by the GNAT team at New York University. --
22 -- Extensive contributions were provided by Ada Core Technologies Inc. --
24 ------------------------------------------------------------------------------
28 private with Ada
.Containers
.Ordered_Sets
;
29 private with Ada
.Strings
.Unbounded
;
31 package VxLink
.Bind
is
33 type VxLink_Binder
is private;
36 (Binder
: out VxLink_Binder
;
37 Object_File
: String);
39 procedure Parse_Tag_File
40 (Binder
: in out VxLink_Binder
;
44 (Binder
: in out VxLink_Binder
;
47 function CTDT_File
(Binder
: VxLink_Binder
) return String;
51 use Ada
.Strings
.Unbounded
;
53 type Symbol_Kind
is (Sym_Ctor
, Sym_Dtor
, Sym_Other
);
56 Name
: Unbounded_String
;
63 function "=" (S1
, S2
: Symbol
) return Boolean
64 is (S1
.Name
= S2
.Name
and then S1
.Cat
= S2
.Cat
);
66 function "<" (S1
, S2
: Symbol
) return Boolean
67 is (if S1
.Priority
/= S2
.Priority
68 then S1
.Priority
< S2
.Priority
69 elsif S1
.Name
/= S2
.Name
70 then S1
.Name
< S2
.Name
71 else S1
.Cat
< S2
.Cat
);
73 package Symbol_Sets
is new Ada
.Containers
.Ordered_Sets
78 type VxLink_Binder
is record
79 CTDT_File
: Unbounded_String
;
80 Constructors
: Symbol_Sets
.Set
;
81 Destructors
: Symbol_Sets
.Set
;
82 Module_Dtor_Needed
: Boolean;
83 EH_Frame_Needed
: Boolean;
84 Tags_List
: Strings_List
.Vector
;