linux-c-programming.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Curry, Matthew Leon" <mlcurry@sandia.gov>
To: "Daniel." <danielhilst@gmail.com>,
	"linux-c-programming@vger.kernel.org"
	<linux-c-programming@vger.kernel.org>
Subject: Re: [EXTERNAL] Is defined() macro portable or GNU only?
Date: Wed, 30 Sep 2015 21:27:46 +0000	[thread overview]
Message-ID: <D231AF64.FCEF%mlcurry@sandia.gov> (raw)
In-Reply-To: <CAF3SDA7TQOz9Vzk+iVzLn2SgxW22R-jARjJ+yzvYkSYXnzzM+A@mail.gmail.com>

It¹s part of ANSI C, and is described in K&R.

Matthew

On 9/30/15, 1:25 PM, "linux-c-programming-owner@vger.kernel.org on behalf
of Daniel." <linux-c-programming-owner@vger.kernel.org on behalf of
danielhilst@gmail.com> wrote:

>Hi all,
>
>I used to check definitions with #ifdef, but in cases where
>multiple macros are checked I use #if defined(foo) && defined(bar).
>Is this defined() check portable/standard? Or is some kind of
>extension added by GCC?
>
>Regards,
>- dhs
>-- 
>"Do or do not. There is no try"
>  Yoda Master
>--
>To unsubscribe from this list: send the line "unsubscribe
>linux-c-programming" in
>the body of a message to majordomo@vger.kernel.org
>More majordomo info at  http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2015-09-30 21:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-30 19:25 Is defined() macro portable or GNU only? Daniel.
2015-09-30 21:27 ` Curry, Matthew Leon [this message]
2015-10-01 13:11   ` [EXTERNAL] " Daniel.

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=D231AF64.FCEF%mlcurry@sandia.gov \
    --to=mlcurry@sandia.gov \
    --cc=danielhilst@gmail.com \
    --cc=linux-c-programming@vger.kernel.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 NNTP newsgroup(s).