public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Gary Oblock <gary@amperecomputing.com>
To: "gcc@gcc.gnu.org" <gcc@gcc.gnu.org>
Subject: A silly question regarding function types
Date: Fri, 4 Sep 2020 02:37:28 +0000	[thread overview]
Message-ID: <BYAPR01MB5464583BB788F2A4B14BB0DFC62D0@BYAPR01MB5464.prod.exchangelabs.com> (raw)

Note, isn't a problem, rather, it's something that puzzles me.

On walking a function types argument types this way

for ( arg = TYPE_ARG_TYPES ( func_type);
       arg != NULL;
       arg = TREE_CHAIN ( arg))
    {
       .
       .
     }

I noticed an extra void argument that didn't exist
tagged on the end.

I then noticed other code doing this (which I copied:)

for ( arg = TYPE_ARG_TYPES ( func_type);
        arg != NULL && arg != void_list_node;
        arg = TREE_CHAIN ( arg))
     {
         .
         .
      }

What is going on here???

Thanks,

Gary



CONFIDENTIALITY NOTICE: This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and contains information that is confidential and proprietary to Ampere Computing or its subsidiaries. It is to be used solely for the purpose of furthering the parties' business relationship. Any unauthorized review, copying, or distribution of this email (or any attachments thereto) is strictly prohibited. If you are not the intended recipient, please contact the sender immediately and permanently delete the original and any copies of this email and any attachments thereto.

             reply	other threads:[~2020-09-04  2:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-04  2:37 Gary Oblock [this message]
2020-09-04  7:13 ` Richard Biener

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=BYAPR01MB5464583BB788F2A4B14BB0DFC62D0@BYAPR01MB5464.prod.exchangelabs.com \
    --to=gary@amperecomputing.com \
    --cc=gcc@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).