This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

preprocessor/8782: concatenating in macro produces strange warnings


>Number:         8782
>Category:       preprocessor
>Synopsis:       concatenating in macro produces strange warnings
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Dec 02 02:46:02 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     ctron@dentrassi.de
>Release:        3.2
>Organization:
>Environment:

>Description:
when using the code from "how-to-repeat" the following macro is emitted. The compilation works, but the warning is anoying.

warning: pasting "::" and "ostream" does not give a valid preprocessing token
>How-To-Repeat:
use the following statements:

#define MACRO(x) std:: ## x

or

#define MACRO(x) std::##x

the warning will be generated altough it works afterwards.
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]