$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: Re: [Boost-users] [preprocessor] different macro expansion depending onwhether its argument is defined or not?
From: Pete Bartlett (pete_at_[hidden])
Date: 2009-10-16 15:05:37
>Hi,
>
>is it possible to write a preprocessor macro which takes one argument
>and which expands differently depending on whether the argument is
>defined or not? Boost solution preferred.
>
>Example:
>
>#define FOO
>#undef BAR
>
>MY_MACRO(FOO) expands to 1
>MY_MACRO(BAR) expands to 0
>
>
>Kind regards
>Ingolf
No, I'm afraid not.