------- Comment #11 from burnus at gcc dot gnu dot org  2010-07-08 13:33 -------
+      /* A temporary is not needed if the lhs has never been host
+        associated and the procedure is contained.  */
+      if (!sym->attr.host_assoc_in_contained
+           && expr2->value.function.esym->attr.contained)
+       return false;
+
       /* A temporary is not needed if the variable is local and not
         a pointer, a target or a result.  */
       if (sym->ns->parent

I have not read the patch in context, but I fear that you might miss a
TARGET/POINTER check. Otherwise, I like your patch.


-- 


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

Reply via email to