diff options
Diffstat (limited to 'gcc/ada/gcc-interface/gigi.h')
-rw-r--r-- | gcc/ada/gcc-interface/gigi.h | 93 |
1 files changed, 40 insertions, 53 deletions
diff --git a/gcc/ada/gcc-interface/gigi.h b/gcc/ada/gcc-interface/gigi.h index 118ce33..4f95d3f 100644 --- a/gcc/ada/gcc-interface/gigi.h +++ b/gcc/ada/gcc-interface/gigi.h @@ -654,23 +654,22 @@ extern tree create_index_type (tree min, tree max, tree index, sizetype is used. */ extern tree create_range_type (tree type, tree min, tree max); -/* Return a TYPE_DECL node suitable for the TYPE_STUB_DECL field of a type. - TYPE_NAME gives the name of the type and TYPE is a ..._TYPE node giving - its data type. */ -extern tree create_type_stub_decl (tree type_name, tree type); - -/* Return a TYPE_DECL node. TYPE_NAME gives the name of the type and TYPE - is a ..._TYPE node giving its data type. ARTIFICIAL_P is true if the - declaration was generated by the compiler. DEBUG_INFO_P is true if we - need to write debug information about this type. GNAT_NODE is used for - the position of the decl. */ -extern tree create_type_decl (tree type_name, tree type, bool artificial_p, +/* Return a TYPE_DECL node suitable for the TYPE_STUB_DECL field of TYPE. + NAME gives the name of the type to be used in the declaration. */ +extern tree create_type_stub_decl (tree name, tree type); + +/* Return a TYPE_DECL node for TYPE. NAME gives the name of the type to be + used in the declaration. ARTIFICIAL_P is true if the declaration was + generated by the compiler. DEBUG_INFO_P is true if we need to write + debug information about this type. GNAT_NODE is used for the position + of the decl. */ +extern tree create_type_decl (tree name, tree type, bool artificial_p, bool debug_info_p, Node_Id gnat_node); /* Return a VAR_DECL or CONST_DECL node. - VAR_NAME gives the name of the variable. ASM_NAME is its assembler name - (if provided). TYPE is its data type (a GCC ..._TYPE node). VAR_INIT is + NAME gives the name of the variable. ASM_NAME is its assembler name + (if provided). TYPE is its data type (a GCC ..._TYPE node). INIT is the GCC tree for an optional initial expression; NULL_TREE if none. CONST_FLAG is true if this variable is constant, in which case we might @@ -691,49 +690,37 @@ extern tree create_type_decl (tree type_name, tree type, bool artificial_p, DEBUG_INFO_P is true if we need to write debug information for it. GNAT_NODE is used for the position of the decl. */ -extern tree -create_var_decl_1 (tree var_name, tree asm_name, tree type, tree var_init, - bool const_flag, bool public_flag, bool extern_flag, - bool static_flag, bool artificial_p, bool debug_info_p, - bool const_decl_allowed_p, struct attrib *attr_list, - Node_Id gnat_node); - -/* Wrapper around create_var_decl_1 for cases where we don't care whether - a VAR or a CONST decl node is created. */ -#define create_var_decl(var_name, asm_name, type, var_init, \ - const_flag, public_flag, extern_flag, \ - static_flag, artificial_p, debug_info_p,\ - attr_list, gnat_node) \ - create_var_decl_1 (var_name, asm_name, type, var_init, \ - const_flag, public_flag, extern_flag, \ - static_flag, artificial_p, debug_info_p, \ - true, attr_list, gnat_node) - -/* Return a FIELD_DECL node. FIELD_NAME is the field's name, FIELD_TYPE is - its type and RECORD_TYPE is the type of the enclosing record. If SIZE is - nonzero, it is the specified size of the field. If POS is nonzero, it is - the bit position. PACKED is 1 if the enclosing record is packed, -1 if it - has Component_Alignment of Storage_Unit. If ADDRESSABLE is nonzero, it +extern tree create_var_decl (tree name, tree asm_name, tree type, tree init, + bool const_flag, bool public_flag, + bool extern_flag, bool static_flag, + bool artificial_p, bool debug_info_p, + struct attrib *attr_list, Node_Id gnat_node, + bool const_decl_allowed_p = true); + +/* Return a FIELD_DECL node. NAME is the field's name, TYPE is its type and + RECORD_TYPE is the type of the enclosing record. If SIZE is nonzero, it + is the specified size of the field. If POS is nonzero, it is the bit + position. PACKED is 1 if the enclosing record is packed, -1 if it has + Component_Alignment of Storage_Unit. If ADDRESSABLE is nonzero, it means we are allowed to take the address of the field; if it is negative, we should not make a bitfield, which is used by make_aligning_type. */ -extern tree create_field_decl (tree field_name, tree field_type, - tree record_type, tree size, tree pos, - int packed, int addressable); +extern tree create_field_decl (tree name, tree type, tree record_type, + tree size, tree pos, int packed, + int addressable); -/* Return a PARM_DECL node. PARAM_NAME is the name of the parameter and - PARAM_TYPE is its type. READONLY is true if the parameter is readonly - (either an In parameter or an address of a pass-by-ref parameter). */ -extern tree create_param_decl (tree param_name, tree param_type, - bool readonly); +/* Return a PARM_DECL node. NAME is the name of the parameter and TYPE is + its type. READONLY is true if the parameter is readonly (either an In + parameter or an address of a pass-by-ref parameter). */ +extern tree create_param_decl (tree name, tree type, bool readonly); -/* Return a LABEL_DECL with LABEL_NAME. GNAT_NODE is used for the position - of the decl. */ -extern tree create_label_decl (tree label_name, Node_Id gnat_node); +/* Return a LABEL_DECL with NAME. GNAT_NODE is used for the position of + the decl. */ +extern tree create_label_decl (tree name, Node_Id gnat_node); -/* Return a FUNCTION_DECL node. SUBPROG_NAME is the name of the subprogram, - ASM_NAME is its assembler name, SUBPROG_TYPE is its type (a FUNCTION_TYPE - node), PARAM_DECL_LIST is the list of the subprogram arguments (a list of - PARM_DECL nodes chained through the DECL_CHAIN field). +/* Return a FUNCTION_DECL node. NAME is the name of the subprogram, ASM_NAME + its assembler name, TYPE its type (a FUNCTION_TYPE node), PARAM_DECL_LIST + the list of its parameters (a list of PARM_DECL nodes chained through the + DECL_CHAIN field). INLINE_STATUS, PUBLIC_FLAG, EXTERN_FLAG and ATTR_LIST are used to set the appropriate fields in the FUNCTION_DECL. @@ -743,8 +730,8 @@ extern tree create_label_decl (tree label_name, Node_Id gnat_node); DEBUG_INFO_P is true if we need to write debug information for it. GNAT_NODE is used for the position of the decl. */ -extern tree create_subprog_decl (tree subprog_name, tree asm_name, - tree subprog_type, tree param_decl_list, +extern tree create_subprog_decl (tree name, tree asm_name, tree type, + tree param_decl_list, enum inline_status_t inline_status, bool public_flag, bool extern_flag, bool artificial_p, bool debug_info_p, |