diff options
author | Alexandre Petit-Bianco <apbianco@cygnus.com> | 2000-07-13 19:27:49 +0000 |
---|---|---|
committer | Alexandre Petit-Bianco <apbianco@gcc.gnu.org> | 2000-07-13 12:27:49 -0700 |
commit | ee97d3542d91ac097597a3b340c80c6c56d49f13 (patch) | |
tree | a6d542bb102539af63a5930b07c3c5cc7cf25e33 /gcc/java/parse.c | |
parent | 185ce11b15dec339ddda83aa7a5fcb4ac200466d (diff) | |
download | gcc-ee97d3542d91ac097597a3b340c80c6c56d49f13.zip gcc-ee97d3542d91ac097597a3b340c80c6c56d49f13.tar.gz gcc-ee97d3542d91ac097597a3b340c80c6c56d49f13.tar.bz2 |
parse.y (fold_constant_for_init): Avoid bullish conversion.
2000-07-13 Alexandre Petit-Bianco <apbianco@cygnus.com>
* parse.y (fold_constant_for_init): Avoid bullish conversion.
(http://gcc.gnu.org/ml/gcc-patches/2000-07/msg00506.html)
From-SVN: r35022
Diffstat (limited to 'gcc/java/parse.c')
-rw-r--r-- | gcc/java/parse.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/gcc/java/parse.c b/gcc/java/parse.c index 5133edf..f1cd122 100644 --- a/gcc/java/parse.c +++ b/gcc/java/parse.c @@ -17508,12 +17508,9 @@ fold_constant_for_init (node, context) tree op0, op1, val; enum tree_code code = TREE_CODE (node); - if (code == STRING_CST) + if (code == STRING_CST || code == INTEGER_CST || code == REAL_CST) return node; - if (code == INTEGER_CST || code == REAL_CST) - return convert (TREE_TYPE (context), node); - switch (code) { case PLUS_EXPR: |