]> granicus.if.org Git - clang/commitdiff
constify some stuff
authorChris Lattner <sabre@nondot.org>
Mon, 27 Aug 2007 17:56:57 +0000 (17:56 +0000)
committerChris Lattner <sabre@nondot.org>
Mon, 27 Aug 2007 17:56:57 +0000 (17:56 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@41503 91177308-0d34-0410-b5e6-96231b3b80d8

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

index 1a740b524570e7f258a0b549b6a835b6b8b6bd30..bc737483d2b6d28f0ce19c4cb48ef6a6e940234a 100644 (file)
@@ -314,8 +314,8 @@ const RecordLayout &ASTContext::getRecordLayout(const RecordDecl *D,
 
 /// getEnumDeclIntegerType - returns the integer type compatible with the
 /// given enum type.
-QualType ASTContext::getEnumDeclIntegerType(EnumDecl *ED) const {
-  if (EnumConstantDecl *C = ED->getEnumConstantList())
+QualType ASTContext::getEnumDeclIntegerType(const EnumDecl *ED) const {
+  if (const EnumConstantDecl *C = ED->getEnumConstantList())
     return C->getType();
 
   // If the enum list is empty, it is typed as if it contained a single zero 
index 8973087a527e8dac38e62cfcb0790d641c71f174..47a433d689c00b8ef5bce7ef76966605589f7837 100644 (file)
@@ -149,7 +149,7 @@ public:
   
   /// getEnumDeclIntegerType - returns the integer type compatible with the
   /// given enum type.
-  QualType getEnumDeclIntegerType(EnumDecl *ED) const;
+  QualType getEnumDeclIntegerType(const EnumDecl *ED) const;
   
   //===--------------------------------------------------------------------===//
   //                            Type Operators