[cfe-commits] r50525 - /cfe/trunk/include/clang/AST/Expr.h

Ted Kremenek kremenek at apple.com
Thu May 1 08:55:24 PDT 2008


Author: kremenek
Date: Thu May  1 10:55:24 2008
New Revision: 50525

URL: http://llvm.org/viewvc/llvm-project?rev=50525&view=rev
Log:
Added comments to ObjCMessageExpr.

Modified:
    cfe/trunk/include/clang/AST/Expr.h

Modified: cfe/trunk/include/clang/AST/Expr.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Expr.h?rev=50525&r1=50524&r2=50525&view=diff

==============================================================================
--- cfe/trunk/include/clang/AST/Expr.h (original)
+++ cfe/trunk/include/clang/AST/Expr.h Thu May  1 10:55:24 2008
@@ -1538,6 +1538,9 @@
     delete [] SubExprs;
   }
   
+  /// getReceiver - Returns the receiver of the message expression.
+  ///  This can be NULL if the message is for instance methods.  For
+  ///  instance methods, use getClassName.
   const Expr *getReceiver() const { return SubExprs[RECEIVER]; }
   Expr *getReceiver() { return SubExprs[RECEIVER]; }
   
@@ -1546,13 +1549,15 @@
   const ObjCMethodDecl *getMethodDecl() const { return MethodProto; }
   ObjCMethodDecl *getMethodDecl() { return MethodProto; }
   
+  /// getClassName - For instance methods, this returns the invoked class,
+  ///  and returns NULL otherwise.  For regular methods, use getReceiver.  
   const IdentifierInfo *getClassName() const { return ClassName; }
   IdentifierInfo *getClassName() { return ClassName; }
   
   /// getNumArgs - Return the number of actual arguments to this call.
   unsigned getNumArgs() const { return NumArgs; }
 
-/// getArg - Return the specified argument.
+  /// getArg - Return the specified argument.
   Expr *getArg(unsigned Arg) {
     assert(Arg < NumArgs && "Arg access out of range!");
     return SubExprs[Arg+ARGS_START];





More information about the cfe-commits mailing list