Author: Eric Christopher Date: 2019-11-25T15:29:33-08:00 New Revision: e8075692589dc1274585bd7445f3e3b830b96c69
URL: https://github.com/llvm/llvm-project/commit/e8075692589dc1274585bd7445f3e3b830b96c69 DIFF: https://github.com/llvm/llvm-project/commit/e8075692589dc1274585bd7445f3e3b830b96c69.diff LOG: Fix an unused variable warning where a variable was only used in an assert. Added: Modified: clang-tools-extra/clangd/AST.cpp Removed: ################################################################################ diff --git a/clang-tools-extra/clangd/AST.cpp b/clang-tools-extra/clangd/AST.cpp index cd6a682007f2..e4d808921c01 100644 --- a/clang-tools-extra/clangd/AST.cpp +++ b/clang-tools-extra/clangd/AST.cpp @@ -457,8 +457,10 @@ std::string getQualification(ASTContext &Context, const DeclContext *DestContext, SourceLocation InsertionPoint, const NamedDecl *ND, llvm::ArrayRef<std::string> VisibleNamespaces) { - for (llvm::StringRef NS : VisibleNamespaces) + for (llvm::StringRef NS : VisibleNamespaces) { assert(NS.endswith("::")); + (void)NS; + } return getQualification( Context, DestContext, ND->getDeclContext(), [&](NestedNameSpecifier *NNS) { _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits