decl.c (gnat_to_gnu_entity): New case to deal with the definition of named numbers.
authorEric Botcazou <ebotcazou@adacore.com>
Fri, 11 Oct 2019 08:19:03 +0000 (08:19 +0000)
committerEric Botcazou <ebotcazou@gcc.gnu.org>
Fri, 11 Oct 2019 08:19:03 +0000 (08:19 +0000)
commit104099b897fe28c5d28b81a83d7655ea3b91c0c8
treeb9d711df9dcd97928a740c08d713f196d23cdb21
parent848830dcf75bf887e7ff59a50a0be1463b7a8570
decl.c (gnat_to_gnu_entity): New case to deal with the definition of named numbers.

* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Named_{Integer|Real}>:
New case to deal with the definition of named numbers.
<E_Variable>: Minor tweaks.  Set DECL_IGNORED_P on the CONST_DECL
if a corresponding variable is built.
* gcc-interface/trans.c (gnat_to_gnu) <N_Integer_Literal>: Return
error_mark_node instead of aborting on overflow for named numbers.
<N_Number_Declaration>: Reuse the <N_Object_Declaration> case and
deal with error_mark_node specifically.
* gcc-interface/utils.c (create_var_decl): Do not set DECL_IGNORED_P
on CONST_DECLs.
(gnat_write_global_declarations): Output global constants.

From-SVN: r276864
gcc/ada/ChangeLog
gcc/ada/gcc-interface/decl.c
gcc/ada/gcc-interface/trans.c
gcc/ada/gcc-interface/utils.c