aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
Diffstat (limited to 'tools')
-rw-r--r--tools/clang-cc/clang-cc.cpp3
-rw-r--r--tools/index-test/index-test.cpp3
2 files changed, 5 insertions, 1 deletions
diff --git a/tools/clang-cc/clang-cc.cpp b/tools/clang-cc/clang-cc.cpp
index 641d1195c2..f1b10c56db 100644
--- a/tools/clang-cc/clang-cc.cpp
+++ b/tools/clang-cc/clang-cc.cpp
@@ -784,6 +784,9 @@ static void InitializeLanguageStandard(LangOptions &Options, LangKind LK,
if (AccessControl)
Options.AccessControl = 1;
+ // OpenCL and C++ both have bool, true, false keywords.
+ Options.Bool = Options.OpenCL | Options.CPlusPlus;
+
Options.MathErrno = MathErrno;
Options.InstantiationDepth = TemplateDepth;
diff --git a/tools/index-test/index-test.cpp b/tools/index-test/index-test.cpp
index d851f5c90b..9b10c55bde 100644
--- a/tools/index-test/index-test.cpp
+++ b/tools/index-test/index-test.cpp
@@ -133,7 +133,8 @@ int main(int argc, char **argv) {
if (Point.Node) {
OS << "Statement node at point: " << Point.Node->getStmtClassName()
<< " ";
- Point.Node->printPretty(OS, AST->getASTContext());
+ Point.Node->printPretty(OS, AST->getASTContext(), 0,
+ PrintingPolicy(AST->getASTContext().getLangOptions()));
OS << "\n";
}
}