Commit 08b8b90c by Eric Botcazou Committed by Eric Botcazou

fe.h (Set_Present_Expr): Move around.

	* fe.h (Set_Present_Expr): Move around.
	(End_Location): New macro.
	* gcc-interface/trans.c (Case_Statement_to_gnu): Use End_Location.

From-SVN: r210587
parent d6d229c6
2014-05-18 Eric Botcazou <ebotcazou@adacore.com> 2014-05-18 Eric Botcazou <ebotcazou@adacore.com>
* fe.h (Set_Present_Expr): Move around.
(End_Location): New macro.
* gcc-interface/trans.c (Case_Statement_to_gnu): Use End_Location.
2014-05-18 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/decl.c (gnat_to_gnu_entity): Use Underlying_Type in * gcc-interface/decl.c (gnat_to_gnu_entity): Use Underlying_Type in
lieu of more verbose construct. lieu of more verbose construct.
* gcc-interface/trans.c (Call_to_gnu): Likewise. * gcc-interface/trans.c (Call_to_gnu): Likewise.
......
...@@ -56,8 +56,7 @@ extern char Fold_Lower[], Fold_Upper[]; ...@@ -56,8 +56,7 @@ extern char Fold_Lower[], Fold_Upper[];
extern Boolean Debug_Flag_NN; extern Boolean Debug_Flag_NN;
/* einfo: We will be setting Esize for types, Component_Bit_Offset for fields, /* einfo: We will be setting Esize for types, Component_Bit_Offset for fields,
Alignment for types and objects, Component_Size for array types, and Alignment for types and objects, Component_Size for array types. */
Present_Expr for N_Variant nodes. */
#define Set_Alignment einfo__set_alignment #define Set_Alignment einfo__set_alignment
#define Set_Component_Bit_Offset einfo__set_component_bit_offset #define Set_Component_Bit_Offset einfo__set_component_bit_offset
...@@ -65,7 +64,6 @@ extern Boolean Debug_Flag_NN; ...@@ -65,7 +64,6 @@ extern Boolean Debug_Flag_NN;
#define Set_Esize einfo__set_esize #define Set_Esize einfo__set_esize
#define Set_Mechanism einfo__set_mechanism #define Set_Mechanism einfo__set_mechanism
#define Set_RM_Size einfo__set_rm_size #define Set_RM_Size einfo__set_rm_size
#define Set_Present_Expr sinfo__set_present_expr
extern void Set_Alignment (Entity_Id, Uint); extern void Set_Alignment (Entity_Id, Uint);
extern void Set_Component_Bit_Offset (Entity_Id, Uint); extern void Set_Component_Bit_Offset (Entity_Id, Uint);
...@@ -73,7 +71,6 @@ extern void Set_Component_Size (Entity_Id, Uint); ...@@ -73,7 +71,6 @@ extern void Set_Component_Size (Entity_Id, Uint);
extern void Set_Esize (Entity_Id, Uint); extern void Set_Esize (Entity_Id, Uint);
extern void Set_Mechanism (Entity_Id, Mechanism_Type); extern void Set_Mechanism (Entity_Id, Mechanism_Type);
extern void Set_RM_Size (Entity_Id, Uint); extern void Set_RM_Size (Entity_Id, Uint);
extern void Set_Present_Expr (Node_Id, Uint);
#define Is_Entity_Name einfo__is_entity_name #define Is_Entity_Name einfo__is_entity_name
extern Boolean Is_Entity_Name (Node_Id); extern Boolean Is_Entity_Name (Node_Id);
...@@ -253,11 +250,15 @@ extern Node_Id First_Actual (Node_Id); ...@@ -253,11 +250,15 @@ extern Node_Id First_Actual (Node_Id);
extern Node_Id Next_Actual (Node_Id); extern Node_Id Next_Actual (Node_Id);
extern Boolean Requires_Transient_Scope (Entity_Id); extern Boolean Requires_Transient_Scope (Entity_Id);
/* sinfo: These functions aren't in sinfo.h since we don't make the /* sinfo: */
setting functions, just the retrieval functions. */
#define End_Location sinfo__end_location
#define Set_Has_No_Elaboration_Code sinfo__set_has_no_elaboration_code #define Set_Has_No_Elaboration_Code sinfo__set_has_no_elaboration_code
#define Set_Present_Expr sinfo__set_present_expr
extern Source_Ptr End_Location (Node_Id);
extern void Set_Has_No_Elaboration_Code (Node_Id, Boolean); extern void Set_Has_No_Elaboration_Code (Node_Id, Boolean);
extern void Set_Present_Expr (Node_Id, Uint);
/* targparm: */ /* targparm: */
......
...@@ -2384,8 +2384,7 @@ Case_Statement_to_gnu (Node_Id gnat_node) ...@@ -2384,8 +2384,7 @@ Case_Statement_to_gnu (Node_Id gnat_node)
/* We build a SWITCH_EXPR that contains the code with interspersed /* We build a SWITCH_EXPR that contains the code with interspersed
CASE_LABEL_EXPRs for each label. */ CASE_LABEL_EXPRs for each label. */
if (!Sloc_to_locus (Sloc (gnat_node) + UI_To_Int (End_Span (gnat_node)), if (!Sloc_to_locus (End_Location (gnat_node), &end_locus))
&end_locus))
end_locus = input_location; end_locus = input_location;
gnu_label = create_artificial_label (end_locus); gnu_label = create_artificial_label (end_locus);
start_stmt_group (); start_stmt_group ();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment