[llvm-branch-commits] [llvm] 3e8d1e8 - [APSInt][NFC] Clean up doxygen comments

Sven van Haastregt via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Fri Jan 22 01:29:14 PST 2021


Author: Sven van Haastregt
Date: 2021-01-22T09:23:41Z
New Revision: 3e8d1e8b12ba9017b861fff94afdd4a29b39de17

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

LOG: [APSInt][NFC] Clean up doxygen comments

Add a Doxygen class comment and clean up other Doxygen comments in
this file while we're at it.

Added: 
    

Modified: 
    llvm/include/llvm/ADT/APSInt.h

Removed: 
    


################################################################################
diff  --git a/llvm/include/llvm/ADT/APSInt.h b/llvm/include/llvm/ADT/APSInt.h
index 0f991826c457..82e9ba81141f 100644
--- a/llvm/include/llvm/ADT/APSInt.h
+++ b/llvm/include/llvm/ADT/APSInt.h
@@ -18,6 +18,7 @@
 
 namespace llvm {
 
+/// An arbitrary precision integer that knows its signedness.
 class LLVM_NODISCARD APSInt : public APInt {
   bool IsUnsigned;
 
@@ -25,8 +26,7 @@ class LLVM_NODISCARD APSInt : public APInt {
   /// Default constructor that creates an uninitialized APInt.
   explicit APSInt() : IsUnsigned(false) {}
 
-  /// APSInt ctor - Create an APSInt with the specified width, default to
-  /// unsigned.
+  /// Create an APSInt with the specified width, default to unsigned.
   explicit APSInt(uint32_t BitWidth, bool isUnsigned = true)
    : APInt(BitWidth, 0), IsUnsigned(isUnsigned) {}
 
@@ -78,11 +78,11 @@ class LLVM_NODISCARD APSInt : public APInt {
   void setIsUnsigned(bool Val) { IsUnsigned = Val; }
   void setIsSigned(bool Val) { IsUnsigned = !Val; }
 
-  /// toString - Append this APSInt to the specified SmallString.
+  /// Append this APSInt to the specified SmallString.
   void toString(SmallVectorImpl<char> &Str, unsigned Radix = 10) const {
     APInt::toString(Str, Radix, isSigned());
   }
-  /// toString - Converts an APInt to a std::string.  This is an inefficient
+  /// Converts an APInt to a std::string.  This is an inefficient
   /// method; you should prefer passing in a SmallString instead.
   std::string toString(unsigned Radix) const {
     return APInt::toString(Radix, isSigned());
@@ -282,15 +282,15 @@ class LLVM_NODISCARD APSInt : public APInt {
     return APSInt(~static_cast<const APInt&>(*this), IsUnsigned);
   }
 
-  /// getMaxValue - Return the APSInt representing the maximum integer value
-  ///  with the given bit width and signedness.
+  /// Return the APSInt representing the maximum integer value with the given
+  /// bit width and signedness.
   static APSInt getMaxValue(uint32_t numBits, bool Unsigned) {
     return APSInt(Unsigned ? APInt::getMaxValue(numBits)
                            : APInt::getSignedMaxValue(numBits), Unsigned);
   }
 
-  /// getMinValue - Return the APSInt representing the minimum integer value
-  ///  with the given bit width and signedness.
+  /// Return the APSInt representing the minimum integer value with the given
+  /// bit width and signedness.
   static APSInt getMinValue(uint32_t numBits, bool Unsigned) {
     return APSInt(Unsigned ? APInt::getMinValue(numBits)
                            : APInt::getSignedMinValue(numBits), Unsigned);
@@ -331,8 +331,8 @@ class LLVM_NODISCARD APSInt : public APInt {
   static APSInt get(int64_t X) { return APSInt(APInt(64, X), false); }
   static APSInt getUnsigned(uint64_t X) { return APSInt(APInt(64, X), true); }
 
-  /// Profile - Used to insert APSInt objects, or objects that contain APSInt
-  ///  objects, into FoldingSets.
+  /// Used to insert APSInt objects, or objects that contain APSInt objects,
+  /// into FoldingSets.
   void Profile(FoldingSetNodeID& ID) const;
 };
 


        


More information about the llvm-branch-commits mailing list