]> gcc.gnu.org Git - gcc.git/commitdiff
(collect_iterators, case SAVE_EXPR): Simplify code added in previous
authorRichard Kenner <kenner@gcc.gnu.org>
Sun, 27 Jun 1993 22:41:45 +0000 (18:41 -0400)
committerRichard Kenner <kenner@gcc.gnu.org>
Sun, 27 Jun 1993 22:41:45 +0000 (18:41 -0400)
change.

From-SVN: r4768

gcc/c-iterate.c

index 09df3e466336f6a3fda68dc2b4cd1c4b6f942832..38c15a237f91bf9f908d74a28d4edf1bac1c1816 100644 (file)
@@ -1,5 +1,5 @@
 /* Build expressions with type checking for C compiler.
-   Copyright (C) 1987, 1988, 1989, 1992 Free Software Foundation, Inc.
+   Copyright (C) 1987, 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
 
 This file is part of GNU CC.
 
@@ -209,12 +209,9 @@ collect_iterators (exp, list)
 
     case SAVE_EXPR:
       /* In each scan, scan a given save_expr only once.  */
-      {
-       tree tail;
-       for (tail = save_exprs; tail; tail = TREE_CHAIN (tail))
-         if (TREE_VALUE (tail) == exp)
-           return list;
-      }
+      if (value_member (exp, save_exprs))
+       return list;
+
       save_exprs = tree_cons (NULL_TREE, exp, save_exprs);
       return collect_iterators (TREE_OPERAND (exp, 0), list);
 
This page took 0.061452 seconds and 5 git commands to generate.