xref: /netbsd/external/gpl3/gcc.old/dist/gcc/c/c-lang.h (revision ec02198a)
110d565efSmrg /* Definitions for C language specific types.
2*ec02198aSmrg    Copyright (C) 2009-2020 Free Software Foundation, Inc.
310d565efSmrg 
410d565efSmrg This file is part of GCC.
510d565efSmrg 
610d565efSmrg GCC is free software; you can redistribute it and/or modify it under
710d565efSmrg the terms of the GNU General Public License as published by the Free
810d565efSmrg Software Foundation; either version 3, or (at your option) any later
910d565efSmrg version.
1010d565efSmrg 
1110d565efSmrg GCC is distributed in the hope that it will be useful, but WITHOUT ANY
1210d565efSmrg WARRANTY; without even the implied warranty of MERCHANTABILITY or
1310d565efSmrg FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
1410d565efSmrg for more details.
1510d565efSmrg 
1610d565efSmrg You should have received a copy of the GNU General Public License
1710d565efSmrg along with GCC; see the file COPYING3.  If not see
1810d565efSmrg <http://www.gnu.org/licenses/>.  */
1910d565efSmrg 
2010d565efSmrg #ifndef GCC_C_LANG_H
2110d565efSmrg #define GCC_C_LANG_H
2210d565efSmrg 
2310d565efSmrg #include "c-family/c-common.h"
2410d565efSmrg 
25c7a68eb7Smrg /* In a RECORD_TYPE, a sorted array of the fields of the type, not a
26c7a68eb7Smrg    tree for size reasons.  */
27c7a68eb7Smrg struct GTY(()) sorted_fields_type {
28c7a68eb7Smrg   int len;
29c7a68eb7Smrg   tree GTY((length ("%h.len"))) elts[1];
30c7a68eb7Smrg };
31c7a68eb7Smrg 
3210d565efSmrg struct GTY(()) lang_type {
3310d565efSmrg   /* In a RECORD_TYPE, a sorted array of the fields of the type.  */
3410d565efSmrg   struct sorted_fields_type * GTY ((reorder ("resort_sorted_fields"))) s;
3510d565efSmrg   /* In an ENUMERAL_TYPE, the min and max values.  */
3610d565efSmrg   tree enum_min;
3710d565efSmrg   tree enum_max;
3810d565efSmrg   /* In a RECORD_TYPE, information specific to Objective-C, such
3910d565efSmrg      as a list of adopted protocols or a pointer to a corresponding
4010d565efSmrg      @interface.  See objc/objc-act.h for details.  */
4110d565efSmrg   tree objc_info;
4210d565efSmrg };
4310d565efSmrg 
4410d565efSmrg struct GTY(()) lang_decl {
4510d565efSmrg   char dummy;
4610d565efSmrg };
4710d565efSmrg 
4810d565efSmrg /* Save and restore the variables in this file and elsewhere
4910d565efSmrg    that keep track of the progress of compilation of the current function.
5010d565efSmrg    Used for nested functions.  */
5110d565efSmrg 
5210d565efSmrg struct GTY(()) language_function {
5310d565efSmrg   struct c_language_function base;
5410d565efSmrg   tree x_break_label;
5510d565efSmrg   tree x_cont_label;
5610d565efSmrg   struct c_switch * GTY((skip)) x_switch_stack;
5710d565efSmrg   struct c_arg_info * GTY((skip)) arg_info;
5810d565efSmrg   int returns_value;
5910d565efSmrg   int returns_null;
6010d565efSmrg   int returns_abnormally;
6110d565efSmrg   int warn_about_return_type;
6210d565efSmrg };
6310d565efSmrg 
6410d565efSmrg /* If non-zero, implicit "omp declare target" attribute is added into the
6510d565efSmrg    attribute lists.  */
6610d565efSmrg extern GTY(()) int current_omp_declare_target_attribute;
6710d565efSmrg 
6810d565efSmrg #endif /* ! GCC_C_LANG_H */
69