From: Andy Wingo Date: Wed, 4 Aug 2021 08:38:24 +0000 (+0200) Subject: [clang][NFC] Fix needless double-parenthisation X-Git-Tag: upstream/15.0.7~30970 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9ae4275557ca10f79af91ca99a2aa79d5dfd7ed3;p=platform%2Fupstream%2Fllvm.git [clang][NFC] Fix needless double-parenthisation Strip a layer of parentheses in TreeTransform::RebuildQualifiedType. Differential Revision: https://reviews.llvm.org/D108359 --- diff --git a/clang/lib/Sema/TreeTransform.h b/clang/lib/Sema/TreeTransform.h index 0aee33a..9c12368 100644 --- a/clang/lib/Sema/TreeTransform.h +++ b/clang/lib/Sema/TreeTransform.h @@ -4745,8 +4745,8 @@ QualType TreeTransform::RebuildQualifiedType(QualType T, SourceLocation Loc = TL.getBeginLoc(); Qualifiers Quals = TL.getType().getLocalQualifiers(); - if (((T.getAddressSpace() != LangAS::Default && - Quals.getAddressSpace() != LangAS::Default)) && + if ((T.getAddressSpace() != LangAS::Default && + Quals.getAddressSpace() != LangAS::Default) && T.getAddressSpace() != Quals.getAddressSpace()) { SemaRef.Diag(Loc, diag::err_address_space_mismatch_templ_inst) << TL.getType() << T;