diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2020-03-03 17:57:51 +0000 |
---|---|---|
committer | Giuliano Belinassi <giuliano.belinassi@usp.br> | 2020-08-17 13:14:12 -0300 |
commit | e23e3fb4d1c03410cfcf6514fd12fe21d68fc8bd (patch) | |
tree | b55521924fb02c92cf0dd0a8643559f87c3cbeed /gcc/ada/gcc-interface/utils.c | |
parent | f18fc3cb0e640005f4d2529d8b307874bd751f69 (diff) | |
download | gcc-e23e3fb4d1c03410cfcf6514fd12fe21d68fc8bd.zip gcc-e23e3fb4d1c03410cfcf6514fd12fe21d68fc8bd.tar.gz gcc-e23e3fb4d1c03410cfcf6514fd12fe21d68fc8bd.tar.bz2 |
[Ada] AI12-0028-1 Import of variadic C functions
2020-06-19 Eric Botcazou <ebotcazou@adacore.com>
gcc/ada/
* gcc-interface/decl.c (gnat_to_gnu_param): Tidy up.
(gnat_to_gnu_subprog_type): For a variadic C function, do not
build unnamed parameters and do not add final void node.
* gcc-interface/misc.c: Include snames.h.
* gcc-interface/trans.c (Attribute_to_gnu): Tidy up.
(Call_to_gnu): Implement support for unnamed parameters in a
variadic C function.
* gcc-interface/utils.c: Include snames.h.
(copy_type): Tidy up.
Diffstat (limited to 'gcc/ada/gcc-interface/utils.c')
-rw-r--r-- | gcc/ada/gcc-interface/utils.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ada/gcc-interface/utils.c b/gcc/ada/gcc-interface/utils.c index fb08b6c..2a6ed04 100644 --- a/gcc/ada/gcc-interface/utils.c +++ b/gcc/ada/gcc-interface/utils.c @@ -50,6 +50,7 @@ #include "types.h" #include "atree.h" #include "nlists.h" +#include "snames.h" #include "uintp.h" #include "fe.h" #include "sinfo.h" @@ -2561,7 +2562,7 @@ copy_type (tree type) } /* And the contents of the language-specific slot if needed. */ - if ((INTEGRAL_TYPE_P (type) || TREE_CODE (type) == REAL_TYPE) + if ((INTEGRAL_TYPE_P (type) || SCALAR_FLOAT_TYPE_P (type)) && TYPE_RM_VALUES (type)) { TYPE_RM_VALUES (new_type) = NULL_TREE; |