From 0f6256d0fa529d6086866e492f964c3b7528b009 Mon Sep 17 00:00:00 2001 From: Steve Naroff Date: Mon, 2 Apr 2007 23:01:44 +0000 Subject: [PATCH] Bug #: Submitted by: Reviewed by: declare getSizeType() const and fix typo in comment... llvm-svn: 39376 --- clang/AST/ASTContext.cpp | 4 ++-- clang/include/clang/AST/ASTContext.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/clang/AST/ASTContext.cpp b/clang/AST/ASTContext.cpp index 7f20964d7ea7..d61365cecfb3 100644 --- a/clang/AST/ASTContext.cpp +++ b/clang/AST/ASTContext.cpp @@ -287,9 +287,9 @@ TypeRef ASTContext::getTagDeclType(TagDecl *Decl) { } /// getSizeType - Return the unique type for "size_t" (C99 7.17), the result -/// of the sizeof operator (C99 6.5.3.4p4). The value to target dependent and +/// of the sizeof operator (C99 6.5.3.4p4). The value is target dependent and /// needs to agree with the definition in . -TypeRef ASTContext::getSizeType() { +TypeRef ASTContext::getSizeType() const { // On Darwin, size_t is defined as a "long unsigned int". // FIXME: should derive from "Target". return UnsignedLongTy; diff --git a/clang/include/clang/AST/ASTContext.h b/clang/include/clang/AST/ASTContext.h index 2524ea399763..4efd61037a80 100644 --- a/clang/include/clang/AST/ASTContext.h +++ b/clang/include/clang/AST/ASTContext.h @@ -81,7 +81,7 @@ public: /// getSizeType - Return the unique type for "size_t" (C99 7.17), defined /// in . The sizeof operator requires this (C99 6.5.3.4p4). - TypeRef getSizeType(); + TypeRef getSizeType() const; private: void InitBuiltinTypes(); void InitBuiltinType(TypeRef &R, BuiltinType::Kind K);