diff options
author | Dmitri Gribenko <gribozavr@gmail.com> | 2019-09-12 12:16:43 +0000 |
---|---|---|
committer | Dmitri Gribenko <gribozavr@gmail.com> | 2019-09-12 12:16:43 +0000 |
commit | 61bc77941ca9d5c3bd3ad147b18279ecb078be88 (patch) | |
tree | f8178e447c5226a8e06efe5e974ae1244e2f581f /lib/Sema/Sema.cpp | |
parent | 4fa80735ed2d1f726cc88b4fd07c0e341920f673 (diff) | |
download | clang-61bc77941ca9d5c3bd3ad147b18279ecb078be88.tar.gz |
Removed some questionable default arguments from setters
Summary:
They can be confusing -- what does it mean to call a setter without a
value? Also, some setters, like `setPrintTemplateTree` had `false` as
the default value!
The callers are largely not using these default arguments anyway.
Subscribers: cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D67491
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@371731 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/Sema.cpp')
-rw-r--r-- | lib/Sema/Sema.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/Sema/Sema.cpp b/lib/Sema/Sema.cpp index 3f4dacbfc1..c2070995f3 100644 --- a/lib/Sema/Sema.cpp +++ b/lib/Sema/Sema.cpp @@ -1307,7 +1307,7 @@ void Sema::EmitCurrentDiagnostic(unsigned DiagID) { PartialDiagnostic(DiagInfo, Context.getDiagAllocator())); } - Diags.setLastDiagnosticIgnored(); + Diags.setLastDiagnosticIgnored(true); Diags.Clear(); return; @@ -1332,7 +1332,7 @@ void Sema::EmitCurrentDiagnostic(unsigned DiagID) { PartialDiagnostic(DiagInfo, Context.getDiagAllocator())); } - Diags.setLastDiagnosticIgnored(); + Diags.setLastDiagnosticIgnored(true); Diags.Clear(); // Now the diagnostic state is clear, produce a C++98 compatibility @@ -1341,7 +1341,7 @@ void Sema::EmitCurrentDiagnostic(unsigned DiagID) { // The last diagnostic which Sema produced was ignored. Suppress any // notes attached to it. - Diags.setLastDiagnosticIgnored(); + Diags.setLastDiagnosticIgnored(true); return; } @@ -1355,7 +1355,7 @@ void Sema::EmitCurrentDiagnostic(unsigned DiagID) { } // Suppress this diagnostic. - Diags.setLastDiagnosticIgnored(); + Diags.setLastDiagnosticIgnored(true); Diags.Clear(); return; } |