[cfe-commits] [patch] Allow redefining c++ operators like "and" in ms mode

Nico Weber thakis at chromium.org
Tue Feb 28 20:14:03 PST 2012


I enabled this always locally and ran all clang tests. They all pass,
except for test/Preprocessor/cxx_oper_keyword.cpp which specifically
tests that "and" and co can't be redefined. So this should be fine?

Nico

On Mon, Feb 27, 2012 at 9:42 PM, Nico Weber <thakis at chromium.org> wrote:
> Hi,
>
> the attached patch allows things like `#define and foo` in ms mode.
> This fixes PR10606.
>
> I'm not sure if this is the right approach: Preprocessor.cpp sets does
> setIdentifierInfo(0) for isCPlusPlusOperatorKeyword()s, and my patch
> sets it back to a "real" identifier info just in time before it's
> needed in ReadMacroName().
>
> Nico



More information about the cfe-commits mailing list