aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-complex.c
diff options
context:
space:
mode:
authorKai Tietz <ktietz70@googlemail.com>2015-11-13 22:24:45 +0000
committerJason Merrill <jason@gcc.gnu.org>2015-11-13 17:24:45 -0500
commit269e63b735d6e4e18367e94e8417b5d5eb799960 (patch)
tree2ab66075ba691c6242d45ab66643cf2f0358a6a5 /gcc/tree-complex.c
parent9514e74fcd529835a8963f91e12e1ee853149095 (diff)
downloadgcc-269e63b735d6e4e18367e94e8417b5d5eb799960.zip
gcc-269e63b735d6e4e18367e94e8417b5d5eb799960.tar.gz
gcc-269e63b735d6e4e18367e94e8417b5d5eb799960.tar.bz2
Add non-folding variants for convert_to_*.
2015-11-13 Kai Tietz <ktietz70@googlemail.com> Marek Polacek <polacek@redhat.com> Jason Merrill <jason@redhat.com> gcc/ * convert.c (maybe_fold_build1_loc): New. (maybe_fold_build2_loc): New. (convert_to_pointer_1): Split out from convert_to_pointer. (convert_to_pointer_nofold): New. (convert_to_real_1): Split out from convert_to_real. (convert_to_real_nofold): New. (convert_to_integer_1): Split out from convert_to_integer. (convert_to_integer_nofold): New. (convert_to_complex_1): Split out from convert_to_complex. (convert_to_complex_nofold): New. * convert.h: Declare new functions. * tree-complex.c (create_one_component_var): Break up line to avoid sequence point issues. gcc/c-family/ * c-lex.c (interpret_float): Use fold_convert. Co-Authored-By: Jason Merrill <jason@redhat.com> Co-Authored-By: Marek Polacek <polacek@redhat.com> From-SVN: r230359
Diffstat (limited to 'gcc/tree-complex.c')
-rw-r--r--gcc/tree-complex.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/tree-complex.c b/gcc/tree-complex.c
index 11d5999..0204cfe 100644
--- a/gcc/tree-complex.c
+++ b/gcc/tree-complex.c
@@ -432,8 +432,8 @@ create_one_component_var (tree type, tree orig, const char *prefix,
if (DECL_NAME (orig) && !DECL_IGNORED_P (orig))
{
const char *name = IDENTIFIER_POINTER (DECL_NAME (orig));
-
- DECL_NAME (r) = get_identifier (ACONCAT ((name, suffix, NULL)));
+ name = ACONCAT ((name, suffix, NULL));
+ DECL_NAME (r) = get_identifier (name);
SET_DECL_DEBUG_EXPR (r, build1 (code, type, orig));
DECL_HAS_DEBUG_EXPR_P (r) = 1;