[clang] e5907c8 - [NFC] Fix hasQualifier comment (#90485)

via cfe-commits cfe-commits at lists.llvm.org
Mon Apr 29 13:14:56 PDT 2024


Author: Jorge Pinto Sousa
Date: 2024-04-29T22:14:53+02:00
New Revision: e5907c88594133e45b8d1d4e29702b96d7f45c77

URL: https://github.com/llvm/llvm-project/commit/e5907c88594133e45b8d1d4e29702b96d7f45c77
DIFF: https://github.com/llvm/llvm-project/commit/e5907c88594133e45b8d1d4e29702b96d7f45c77.diff

LOG: [NFC] Fix hasQualifier comment (#90485)

operator bool from NestedNameSpecifierLoc and
member function hasQualifier both do the same thing, returning true if
the private data member Qualifier is not nullptr, so clearly one of the
comments is wrong, and in this case it is the second one.

fixes https://github.com/llvm/llvm-project/issues/90472

Added: 
    

Modified: 
    clang/include/clang/AST/NestedNameSpecifier.h

Removed: 
    


################################################################################
diff  --git a/clang/include/clang/AST/NestedNameSpecifier.h b/clang/include/clang/AST/NestedNameSpecifier.h
index 7b0c21b9e7cfb1..a1d9e30e660d14 100644
--- a/clang/include/clang/AST/NestedNameSpecifier.h
+++ b/clang/include/clang/AST/NestedNameSpecifier.h
@@ -266,7 +266,7 @@ class NestedNameSpecifierLoc {
   explicit operator bool() const { return Qualifier; }
 
   /// Evaluates true when this nested-name-specifier location is
-  /// empty.
+  /// non-empty.
   bool hasQualifier() const { return Qualifier; }
 
   /// Retrieve the nested-name-specifier to which this instance


        


More information about the cfe-commits mailing list