summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorJacob Bandes-Storch <jacob@bandes-stor.ch>2018-07-17 04:56:22 +0000
committerJacob Bandes-Storch <jacob@bandes-stor.ch>2018-07-17 04:56:22 +0000
commit33f3e630b47384db957481f7f7aca99b6f37b3a6 (patch)
treec49e1f5f0c07ddbdeda1335017ce65284807652f /clang/lib/Frontend/CompilerInvocation.cpp
parentfec4c1a101996f203388d19160cc279b1bc5618f (diff)
downloadbcm5719-llvm-33f3e630b47384db957481f7f7aca99b6f37b3a6.tar.gz
bcm5719-llvm-33f3e630b47384db957481f7f7aca99b6f37b3a6.zip
[Driver] Add -fno-digraphs
Summary: Add a flag `-fno-digraphs` to disable digraphs in the lexer, similar to `-fno-operator-names` which disables alternative names for C++ operators. Reviewers: rsmith Reviewed By: rsmith Subscribers: rsmith, cfe-commits Differential Revision: https://reviews.llvm.org/D48266 llvm-svn: 337232
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
-rw-r--r--clang/lib/Frontend/CompilerInvocation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp
index f57f23a0d4c..d62429dc788 100644
--- a/clang/lib/Frontend/CompilerInvocation.cpp
+++ b/clang/lib/Frontend/CompilerInvocation.cpp
@@ -2173,6 +2173,8 @@ static void ParseLangArgs(LangOptions &Opts, ArgList &Args, InputKind IK,
Opts.GNUKeywords = Args.hasFlag(OPT_fgnu_keywords, OPT_fno_gnu_keywords,
Opts.GNUKeywords);
+ Opts.Digraphs = Args.hasFlag(OPT_fdigraphs, OPT_fno_digraphs, Opts.Digraphs);
+
if (Args.hasArg(OPT_fno_operator_names))
Opts.CXXOperatorNames = 0;
OpenPOWER on IntegriCloud