]> granicus.if.org Git - clang/commitdiff
Tweak a comment and assert.
authorSteve Naroff <snaroff@apple.com>
Mon, 27 Aug 2007 01:41:48 +0000 (01:41 +0000)
committerSteve Naroff <snaroff@apple.com>
Mon, 27 Aug 2007 01:41:48 +0000 (01:41 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@41475 91177308-0d34-0410-b5e6-96231b3b80d8

AST/ASTContext.cpp
include/clang/AST/ASTContext.h

index 919cc9e2e21d1b4c1ca535a733373bc6a5408ff4..b0b963c4c801a48ae5640b6f34d7db33e0715dcc 100644 (file)
@@ -685,14 +685,15 @@ static int getFloatingRank(QualType T) {
   }
 }
 
-/// getFloatingTypeOfSizeWithinDomain - Returns the either a real floating 
-/// point type or a complex type (based on typeDomain) of typeSize. 
-/// typeSize is expected to be a floating point type (real or complex).
+/// getFloatingTypeOfSizeWithinDomain - Returns a real floating 
+/// point or a complex type (based on typeDomain/typeSize). 
+/// 'typeDomain' is a real floating point or complex type.
+/// 'typeSize' is a real floating point or complex type.
 QualType ASTContext::getFloatingTypeOfSizeWithinDomain(
   QualType typeSize, QualType typeDomain) const {
   if (typeDomain->isComplexType()) {
     switch (getFloatingRank(typeSize)) {
-    default: assert(0 && "convertRankToComplex(): illegal value for rank");
+    default: assert(0 && "getFloatingRank(): illegal value for rank");
     case FloatRank:      return FloatComplexTy;
     case DoubleRank:     return DoubleComplexTy;
     case LongDoubleRank: return LongDoubleComplexTy;
@@ -700,7 +701,7 @@ QualType ASTContext::getFloatingTypeOfSizeWithinDomain(
   }
   if (typeDomain->isRealFloatingType()) {
     switch (getFloatingRank(typeSize)) {
-    default: assert(0 && "convertRankToComplex(): illegal value for rank");
+    default: assert(0 && "getFloatingRank(): illegal value for rank");
     case FloatRank:      return FloatTy;
     case DoubleRank:     return DoubleTy;
     case LongDoubleRank: return LongDoubleTy;
index 2239118a5dd26608084dd84d0c9c7b743b60244d..431d298471b02c5660efacad088049e480dfc89f 100644 (file)
@@ -164,9 +164,10 @@ public:
   /// different combos: float/float, float/complex, complex/complex.
   static QualType maxFloatingType(QualType lt, QualType rt);
 
-  /// getFloatingTypeOfSizeWithinDomain - Returns the either a real floating 
-  /// point type or a complex type (based on typeDomain) of typeSize. 
-  /// typeSize is expected to be a floating point type (real or complex).
+  /// getFloatingTypeOfSizeWithinDomain - Returns a real floating 
+  /// point or a complex type (based on typeDomain/typeSize). 
+  /// 'typeDomain' is a real floating point or complex type.
+  /// 'typeSize' is a real floating point or complex type.
   QualType getFloatingTypeOfSizeWithinDomain(QualType typeSize, 
                                              QualType typeDomain) const;
 private: