Added VxWorks subsection to chapter on getting in/out
[deliverable/binutils-gdb.git] / ld / ldexp.h
CommitLineData
2fa0b342
DHW
1/* ldexp.h -
2
3 Copyright (C) 1991 Free Software Foundation, Inc.
4
5 This file is part of GLD, the Gnu Linker.
6
7 GLD is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 1, or (at your option)
10 any later version.
11
12 GLD is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with GLD; see the file COPYING. If not, write to
19 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
20
21
22
23
24/* The result of an expression tree */
25typedef struct
26{
27 bfd_vma value;
28 struct lang_output_section_statement_struct *section;
29 boolean valid;
30} etree_value_type;
31
32
33
34typedef struct
35{
36 int node_code;
37 enum { etree_binary,
38 etree_trinary,
39 etree_unary,
40 etree_name,
41 etree_assign,
42 etree_undef,
43 etree_unspec,
44 etree_value } node_class;
45} node_type;
46
47
48
49typedef union etree_union
50{
51 node_type type;
52 struct {
53 node_type type;
54 union etree_union *lhs;
55 union etree_union *rhs;
56 } binary;
57 struct {
58 node_type type;
59 union etree_union *cond;
60 union etree_union *lhs;
61 union etree_union *rhs;
62 } trinary;
63 struct {
64 node_type type;
65 char *dst;
66 union etree_union *src;
67 } assign;
68
69 struct {
70 node_type type;
71 union etree_union *child;
72 } unary;
73 struct {
74 node_type type;
75 char *name;
76 } name;
77 struct {
78 node_type type;
79 bfd_vma value;
80 } value;
81
82} etree_type;
83
84
85PROTO(etree_type *,exp_intop,(bfd_vma));
86
87PROTO(etree_value_type, invalid,(void));
88PROTO(etree_value_type, exp_fold_tree,(etree_type *, struct
89 lang_output_section_statement_struct *, lang_phase_type,
90 bfd_vma, bfd_vma *));
91
92PROTO(etree_type *, exp_binop,(int, etree_type *, etree_type *));
93PROTO(etree_type *,exp_trinop,(int,etree_type *, etree_type *, etree_type *));
94PROTO(etree_type *,exp_unop,(int, etree_type *));
95PROTO(etree_type *,exp_nameop,(int, char *));
96PROTO(etree_type *,exp_assop,(int, char *, etree_type *));
97PROTO(void, exp_print_tree,(struct _iobuf *, etree_type *));
98PROTO(bfd_vma, exp_get_vma,(etree_type *, bfd_vma, char *, enum boolean));
99PROTO(int, exp_get_value_int,(etree_type *, int, char *, enum boolean));
This page took 0.026334 seconds and 4 git commands to generate.