This is an archive of the discontinued LLVM Phabricator instance.

[Concepts] lex keywords: concept and requires
ClosedPublic

Authored by hubert.reinterpretcast on Jun 3 2015, 9:26 PM.

Details

Summary

This patch enables lexing of concept and requires as keywords.
Further changes which add messages for future keyword compat are to
follow.

Diff Detail

Event Timeline

hubert.reinterpretcast retitled this revision from to [Concepts] lex keywords: concept and requires.
hubert.reinterpretcast updated this object.
hubert.reinterpretcast edited the test plan for this revision. (Show Details)
hubert.reinterpretcast added a subscriber: Unknown Object (MLST).

This looks fine to me. Just one question: since we are setting -std=c++14,
is there no define for -DCXX14 instead of having to set -DCXX11? If this is
clang policy, then LGTM, otherwise, why are we not adding a define for
C++14?

This looks fine to me. Just one question: since we are setting -std=c++14,
is there no define for -DCXX14 instead of having to set -DCXX11? If this is
clang policy, then LGTM, otherwise, why are we not adding a define for
C++14?

In the context of this test file, CXX14 would be redundant because there are no new keywords introduced through C++14. The corresponding implementation of keywords in the compiler does not call out C++14 apart from C++11. This change is consistent with that.

rsmith accepted this revision.Jun 4 2015, 2:28 PM
rsmith edited edge metadata.

LGTM

This revision is now accepted and ready to land.Jun 4 2015, 2:28 PM