[cfe-commits] r74861 - /cfe/trunk/include/clang/Index/ASTLocation.h
Argiris Kirtzidis
akyrtzi at gmail.com
Mon Jul 6 14:35:09 PDT 2009
Author: akirtzidis
Date: Mon Jul 6 16:35:09 2009
New Revision: 74861
URL: http://llvm.org/viewvc/llvm-project?rev=74861&view=rev
Log:
Add some comments to the ASTLocation class.
Modified:
cfe/trunk/include/clang/Index/ASTLocation.h
Modified: cfe/trunk/include/clang/Index/ASTLocation.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Index/ASTLocation.h?rev=74861&r1=74860&r2=74861&view=diff
==============================================================================
--- cfe/trunk/include/clang/Index/ASTLocation.h (original)
+++ cfe/trunk/include/clang/Index/ASTLocation.h Mon Jul 6 16:35:09 2009
@@ -28,6 +28,12 @@
/// \brief Represents a Decl or a Stmt and its immediate Decl parent. It's
/// immutable.
+///
+/// ASTLocation is intended to be used as a "pointer" into the AST. It is either
+/// just a Decl, or a Stmt and its Decl parent. Since a single Stmt is devoid
+/// of context, its parent Decl provides all the additional missing information
+/// like the declaration context, ASTContext, etc.
+///
class ASTLocation {
Decl *D;
Stmt *Stm;
More information about the cfe-commits
mailing list