Fix typo in index comparison of CONSTRUCTOR.
authorMartin Liska <mliska@suse.cz>
Mon, 3 Jun 2019 10:42:14 +0000 (12:42 +0200)
committerMartin Liska <marxin@gcc.gnu.org>
Mon, 3 Jun 2019 10:42:14 +0000 (10:42 +0000)
2019-06-03  Martin Liska  <mliska@suse.cz>

* fold-const.c (operand_equal_p): Fix typo as compare_tree_int
returns 0 when operands are equal.

From-SVN: r271859

gcc/ChangeLog
gcc/fold-const.c

index 7aabe88b4d8d38014d0ddc7ce7b558c3db0142cf..6529d0e24a0c71c9b55bf19ec28c493725794d01 100644 (file)
@@ -1,3 +1,8 @@
+2019-06-03  Martin Liska  <mliska@suse.cz>
+
+       * fold-const.c (operand_equal_p): Fix typo as compare_tree_int
+       returns 0 when operands are equal.
+
 2019-06-03  Richard Biener  <rguenther@suse.de>
 
        PR tree-optimization/90716
index 42289013cc11b65efafbc4780c8f34899596d0db..3e066a2ecc49008264fb279d30653a4c100a69e9 100644 (file)
@@ -3508,10 +3508,10 @@ operand_equal_p (const_tree arg0, const_tree arg1, unsigned int flags)
                     positives for GENERIC.  */
                  || (c0->index
                      && (TREE_CODE (c0->index) != INTEGER_CST 
-                         || !compare_tree_int (c0->index, i)))
+                         || compare_tree_int (c0->index, i)))
                  || (c1->index
                      && (TREE_CODE (c1->index) != INTEGER_CST 
-                         || !compare_tree_int (c1->index, i))))
+                         || compare_tree_int (c1->index, i))))
                return 0;
            }
          return 1;