[PATCH] D82563: [Sema][NFC] Remove Redundant Condition

Balogh, Ádám via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jul 1 00:30:15 PDT 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rG40c50bdee443: [Sema][NFC] Remove Redundant Condition (authored by baloghadamsoftware).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D82563/new/

https://reviews.llvm.org/D82563

Files:
  clang/lib/Sema/SemaType.cpp


Index: clang/lib/Sema/SemaType.cpp
===================================================================
--- clang/lib/Sema/SemaType.cpp
+++ clang/lib/Sema/SemaType.cpp
@@ -1759,7 +1759,7 @@
     //   The effect of a cv-qualifier-seq in a function declarator is not the
     //   same as adding cv-qualification on top of the function type. In the
     //   latter case, the cv-qualifiers are ignored.
-    if (TypeQuals && Result->isFunctionType()) {
+    if (Result->isFunctionType()) {
       diagnoseAndRemoveTypeQualifiers(
           S, DS, TypeQuals, Result, DeclSpec::TQ_const | DeclSpec::TQ_volatile,
           S.getLangOpts().CPlusPlus


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82563.274698.patch
Type: text/x-patch
Size: 645 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200701/66934948/attachment-0001.bin>


More information about the cfe-commits mailing list