This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/34387] FAIL: gfortran.dg/optional_dim_2.f90: FE vs library argument missmatch



------- Comment #10 from jvdelisle at gcc dot gnu dot org  2008-01-04 05:00 -------
Notice in the tree dump that dimmy is already a pointer type when passed into
the subroutine.

Can you try this patch and see if it works and also send me the fdump tree
original?

Index: trans-expr.c
===================================================================
--- trans-expr.c        (revision 131316)
+++ trans-expr.c        (working copy)
@@ -156,13 +156,12 @@ gfc_conv_missing_dummy (gfc_se * se, gfc

   tmp = build3 (COND_EXPR, TREE_TYPE (se->expr), present, se->expr,
                  fold_convert (TREE_TYPE (se->expr), integer_zero_node));
-  tmp = gfc_evaluate_now (tmp, &se->pre);

   if (kind > 0)
     {
       tmp = gfc_get_int_type (kind);
+      tmp = build_pointer_type (tmp);
       tmp = fold_convert (tmp, se->expr);
-      tmp = gfc_evaluate_now (tmp, &se->pre); 
     }

   se->expr = tmp;


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34387


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]