OSDN Git Service

* trans-const.c (gfc_conv_constant_to_tree): Use correct tree
authortobi <tobi@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 5 Mar 2005 20:14:52 +0000 (20:14 +0000)
committertobi <tobi@138bc75d-0d04-0410-961f-82ee72b054a4>
Sat, 5 Mar 2005 20:14:52 +0000 (20:14 +0000)
type for COMPLEX constants.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@95941 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/fortran/ChangeLog
gcc/fortran/trans-const.c

index db94aa6..1490ed1 100644 (file)
@@ -1,3 +1,8 @@
+2005-03-05  Tobias Schl"uter  <tobias.schlueter@physik.uni-muenchen.de>
+
+       * trans-const.c (gfc_conv_constant_to_tree): Use correct tree
+       type for COMPLEX constants.
+
 2005-03-04  Tobias Schl"uter  <tobias.schlueter@physik.uni-muenchen.de>
 
        PR fortran/19673
index 382bbbe..84a62e8 100644 (file)
@@ -316,7 +316,8 @@ gfc_conv_constant_to_tree (gfc_expr * expr)
        tree imag = gfc_conv_mpfr_to_tree (expr->value.complex.i,
                                          expr->ts.kind);
 
-       return build_complex (NULL_TREE, real, imag);
+       return build_complex (gfc_typenode_for_spec (&expr->ts),
+                             real, imag);
       }
 
     case BT_CHARACTER: