diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-11-12 10:55:37 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-11-12 10:55:37 +0000 |
commit | 28e28b297758dd4eeed0f66ddfe53be4db4c8078 (patch) | |
tree | 34ae13ea914b1a19196c1f49ae686f6b549cc8aa /gcc/ada/gcc-interface/utils.c | |
parent | 3ea9a9382fd8b53498a796d4593cb0c2f35d797b (diff) |
2015-11-12 Pierre-Marie de Rodat <derodat@adacore.com>
* gcc-interface/decl.c (gnat_to_gnu_entity): Create
IMPORTED_DECL nodes to describe the subprogram renamings which
are relevant at debug time.
* gcc-interface/gigi.h (get_debug_scope): Add declaration.
* gcc-interface/trans.c (Identifier_to_gnu): Consider
N_Defining_Operator_Symbol as valid entities.
(gnat_to_gnu): Handle N_Defining_Operator_Symbol the same way as
other entities. Introduce a specific handling for
N_Subprogram_Renaming_Declaration: call gnat_to_gnu_entity on
the entity defined for relevant ones.
(process_decls): Process subprogram renaming declarations during
the second pass only.
* gcc-interface/utils.c (get_debug_scope): Make it external.
Consider N_Defining_Operator_Symbol as valid entities.
(gnat_write_global_declarations): Output debugging information
for top-level imported declarations.
* gcc-interface/Makefile.in: Fix typo.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@230227 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/gcc-interface/utils.c')
-rw-r--r-- | gcc/ada/gcc-interface/utils.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/ada/gcc-interface/utils.c b/gcc/ada/gcc-interface/utils.c index 1e9e93614c6a..b032ae03df7b 100644 --- a/gcc/ada/gcc-interface/utils.c +++ b/gcc/ada/gcc-interface/utils.c @@ -585,7 +585,7 @@ gnat_set_type_context (tree type, tree context) the debug info, or Empty if there is no such scope. If not NULL, set IS_SUBPROGRAM to whether the returned entity is a subprogram. */ -static Entity_Id +Entity_Id get_debug_scope (Node_Id gnat_node, bool *is_subprogram) { Entity_Id gnat_entity; @@ -593,7 +593,8 @@ get_debug_scope (Node_Id gnat_node, bool *is_subprogram) if (is_subprogram) *is_subprogram = false; - if (Nkind (gnat_node) == N_Defining_Identifier) + if (Nkind (gnat_node) == N_Defining_Identifier + || Nkind (gnat_node) == N_Defining_Operator_Symbol) gnat_entity = Scope (gnat_node); else return Empty; |