[cfe-commits] r38962 - /cfe/cfe/trunk/include/clang/AST/Decl.h

sabre at cs.uiuc.edu sabre at cs.uiuc.edu
Wed Jul 11 09:26:17 PDT 2007


Author: sabre
Date: Wed Jul 11 11:26:17 2007
New Revision: 38962

URL: http://llvm.org/viewvc/llvm-project?rev=38962&view=rev
Log:
add accessor

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

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

==============================================================================
--- cfe/cfe/trunk/include/clang/AST/Decl.h (original)
+++ cfe/cfe/trunk/include/clang/AST/Decl.h Wed Jul 11 11:26:17 2007
@@ -40,19 +40,16 @@
   ///
   SourceLocation Loc;
   
-#if 0
-  /// Next - Decls are chained together in a singly-linked list by their owning
-  /// object.  Currently we allow decls to be owned by a translation unit or a
-  /// function.  This way we can deallocate a function body and all the
-  /// declarations within it.
-#endif
-  // Scope stack info when parsing, otherwise decl list when scope is popped.
+  /// Scope stack info when parsing, otherwise decl list when scope is popped.
+  ///
   Decl *Next;
 public:
   Decl(IdentifierInfo *Id, const DeclSpec &DS, SourceLocation loc, Decl *next)
     : Identifier(Id), DeclarationSpecifier(DS), Loc(loc), Next(next) {}
   
   
+  const IdentifierInfo *getIdentifier() const { return Identifier; }
+  
   const DeclSpec &getDeclSpecs() const { return DeclarationSpecifier; }
   
   Decl *getNext() const { return Next; }





More information about the cfe-commits mailing list