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]

Re: Macro and namespace


> At least a better error message should be given: "parse error before `('" is
> quite irritating, and it was so even more in the original context, when
> there were indeed brackets in that line.

Thanks for your bug report. Please understand that this is quite
difficult to do: Once the preprocessor is done, all information is
lost what the original text was.

> Does errno belong to the namespace std? If so, gcc should be able to cope
> with it - by ignoring an isolated "std::"? But that is, at least partially,
> a library problem.

According to the C++ standard, errno is a macro. As such, it is not
scoped. Therefore, writing 'std::errno' is invalid C++.

Regards,
Martin


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