* tree.c (build1): Fix off-by-one error.
authorJason Merrill <jason@redhat.com>
Tue, 21 Oct 2003 14:24:28 +0000 (10:24 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Tue, 21 Oct 2003 14:24:28 +0000 (10:24 -0400)
From-SVN: r72754

gcc/ChangeLog
gcc/tree.c

index 372c3bf3beab66919b4794a0b2dfc554b0b78f35..fdba0d3ff31d19afa057cec8d64d7b9d00810d9c 100644 (file)
@@ -1,3 +1,7 @@
+2003-10-21  Jason Merrill  <jason@redhat.com>
+
+       * tree.c (build1): Fix off-by-one error.
+
 2003-09-28  Robert Millan  <robertmh@gnu.org>
 
        * config/i386/kfreebsdgnu.h: New. i386-*-kfreebsd-gnu definitions.
index fef9826730502e0a0c06859eabbcc37aec772bcc..dd8378e8ec562a8e62de3017f36f174c4534416b 100644 (file)
@@ -2478,7 +2478,7 @@ build1 (enum tree_code code, tree type, tree node)
              TREE_SIDE_EFFECTS (t) = 0;
              if (!DECL_P (node))
                {
-                 int i = first_rtl_op (TREE_CODE (node));
+                 int i = first_rtl_op (TREE_CODE (node)) - 1;
                  for (; i >= 0; --i)
                    {
                      if (TREE_SIDE_EFFECTS (TREE_OPERAND (node, i)))