From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16068 invoked by alias); 10 Feb 2003 23:06:02 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 16039 invoked by uid 71); 10 Feb 2003 23:06:01 -0000 Date: Mon, 10 Feb 2003 23:06:00 -0000 Message-ID: <20030210230601.16038.qmail@sources.redhat.com> To: nobody@gcc.gnu.org Cc: gcc-prs@gcc.gnu.org, From: Neil Booth Subject: Re: preprocessor/9650: string literal contactenation doesn't work with #include Reply-To: Neil Booth X-SW-Source: 2003-02/txt/msg00468.txt.bz2 List-Id: The following reply was made to PR preprocessor/9650; it has been noted by GNATS. From: Neil Booth To: frey waid Cc: neil@gcc.gnu.org, gcc-bugs@gcc.gnu.org, gcc-prs@gcc.gnu.org, nobody@gcc.gnu.org, gcc-gnats@gcc.gnu.org Subject: Re: preprocessor/9650: string literal contactenation doesn't work with #include Date: Mon, 10 Feb 2003 23:03:52 +0000 Neil Booth wrote:- > frey waid wrote:- > > > that's what i was doing before. so i had this: > > > > #include COMP_INC(comp,file) > > > > #define COMP_INC(comp,file) #comp "/include/" #file > > > > do you have another method in mind? > > Sure 8-) > > #include COMP_INC (comp, file) > > #define COMP_INC(comp, file) COMP (comp, file) > #define COMP(prefix, suffix) str(comp/include/file) Aargh! Close but no cigar. #define COMP(prefix, suffix) str(prefix/include/suffix) > #define str(x) #x > > Not tested, but you get the idea. Neil.