This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Spaces in macro expansion in a #include?
- From: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- To: "xuinkrbin." <gcc dot 20 dot xuinkrbin at spamgourmet dot com>
- Cc: gcc-help <gcc-help at gcc dot gnu dot org>
- Date: Mon, 31 Mar 2014 18:07:07 +0100
- Subject: Re: Spaces in macro expansion in a #include?
- Authentication-results: sourceware.org; auth=none
- References: <1396284835084-1022862 dot post at n5 dot nabble dot com>
On 31 March 2014 17:53, xuinkrbin. wrote:
> Given a macro:
>
> #define A(x) #x
> #define B 1
> #define C 2
> #define D B C
>
> If I have the following:
>
> #include A(D)
>
> GCC seems to expand the macro to:
>
> "12"
>
> and search for a file named "12" instead of "1 2".
When I try that it searches for a file named "D"