kpet added a comment.
Something I should probably have explained in the commit message is that the
functionality provided by `restrict` is already present in C++, where it is
already exposed using different keywords. If you look at
`clang/include/clang/Basic/TokenKinds.def`, there are `__restri
Anastasia added a comment.
Can you please explain why we are deviating from C++ on this? My concern is
that this can potentially uncover bugs in C++ parsing due to un-handled
restrict cases that would have to be fixed in some unclear way... I would
appreciate more detailed analysis before we go
kpet added a comment.
There doesn't seem to be a test for this (enabling `restrict` in C++ doesn't
make any existing test fail). I couldn't find any test checking that OpenCL or
C++/OpenCL keywords generally aren't enabled in C or C++. Doing this
generically would essentially equate to writing
lebedev.ri added a comment.
Is there a test that shows that that keyword is still not provided for C++
after this?
Repository:
rC Clang
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D68388/new/
https://reviews.llvm.org/D68388
___
cfe-com
kpet created this revision.
kpet added a reviewer: Anastasia.
Herald added subscribers: cfe-commits, kristof.beyls, yaxunl.
Herald added a project: clang.
Just enable it in C++ for OpenCL but not in C++.
Signed-off-by: Kevin Petit
Repository:
rC Clang
https://reviews.llvm.org/D68388
Files: