]> git.ipfire.org Git - thirdparty/gcc.git/blob - gcc/m2/gm2-gcc/m2tree.h
Update copyright years.
[thirdparty/gcc.git] / gcc / m2 / gm2-gcc / m2tree.h
1 /* m2tree.h header file for m2tree.cc.
2
3 Copyright (C) 2012-2024 Free Software Foundation, Inc.
4 Contributed by Gaius Mulley <gaius@glam.ac.uk>.
5
6 This file is part of GNU Modula-2.
7
8 GNU Modula-2 is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3, or (at your option)
11 any later version.
12
13 GNU Modula-2 is distributed in the hope that it will be useful, but
14 WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with GNU Modula-2; see the file COPYING3. If not see
20 <http://www.gnu.org/licenses/>. */
21
22 #if !defined(m2tree_h)
23 #define m2tree_h
24 #if defined(m2tree_c)
25 #if defined(__GNUG__)
26 #define EXTERN extern "C"
27 #else /* !__GNUG__. */
28 #define EXTERN
29 #endif /* !__GNUG__. */
30 #else /* m2tree_c. */
31 #if defined(__GNUG__)
32 #define EXTERN extern "C"
33 #else /* !__GNUG__. */
34 #define EXTERN extern
35 #endif /* !__GNUG__. */
36 #endif /* m2tree_c. */
37
38 #include "input.h"
39 #include <stdbool.h>
40
41 EXTERN bool m2tree_is_var (tree var);
42 EXTERN bool m2tree_is_array (tree array);
43 EXTERN bool m2tree_is_type (tree type);
44 EXTERN tree m2tree_skip_type_decl (tree type);
45 EXTERN tree m2tree_skip_const_decl (tree exp);
46 EXTERN bool m2tree_IsTreeOverflow (tree value);
47 EXTERN bool m2tree_IsOrdinal (tree type);
48 EXTERN bool m2tree_IsAConstant (tree t);
49 EXTERN void m2tree_debug_tree (tree t);
50 EXTERN tree m2tree_skip_reference_type (tree exp);
51
52
53 #ifndef SET_WORD_SIZE
54 /* gross hack. */
55 #define SET_WORD_SIZE INT_TYPE_SIZE
56 #endif /* SET_WORD_SIZE. */
57
58 #undef EXTERN
59 #endif /* m2tree_h. */