public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Patrick Palka <ppalka@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r12-5404] c++: cp_walk_subtrees simplification for *_CAST_EXPR
Date: Fri, 19 Nov 2021 14:01:33 +0000 (GMT)	[thread overview]
Message-ID: <20211119140133.8E1E53858D3C@sourceware.org> (raw)

https://gcc.gnu.org/g:cb09215ad0bbc96fd67aac16004d2131739df096

commit r12-5404-gcb09215ad0bbc96fd67aac16004d2131739df096
Author: Patrick Palka <ppalka@redhat.com>
Date:   Fri Nov 19 09:01:09 2021 -0500

    c++: cp_walk_subtrees simplification for *_CAST_EXPR
    
    Let walk_tree_1 do the operand walking for us.
    
    gcc/cp/ChangeLog:
    
            * tree.c (cp_walk_subtrees) <case *_CAST_EXPR>: Don't explicitly
            walk the operands.

Diff:
---
 gcc/cp/tree.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 32ddf835a91..7050a53abc2 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -5352,13 +5352,6 @@ cp_walk_subtrees (tree *tp, int *walk_subtrees_p, walk_tree_fn func,
     case BIT_CAST_EXPR:
       if (TREE_TYPE (*tp))
 	WALK_SUBTREE (TREE_TYPE (*tp));
-
-      {
-        int i;
-        for (i = 0; i < TREE_CODE_LENGTH (TREE_CODE (*tp)); ++i)
-	  WALK_SUBTREE (TREE_OPERAND (*tp, i));
-      }
-      *walk_subtrees_p = 0;
       break;
 
     case CONSTRUCTOR:


                 reply	other threads:[~2021-11-19 14:01 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211119140133.8E1E53858D3C@sourceware.org \
    --to=ppalka@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).