[cfe-commits] r70909 - /cfe/trunk/include/clang/AST/RecordLayout.h

Daniel Dunbar daniel at zuster.org
Mon May 4 14:00:41 PDT 2009


Author: ddunbar
Date: Mon May  4 16:00:40 2009
New Revision: 70909

URL: http://llvm.org/viewvc/llvm-project?rev=70909&view=rev
Log:
Add ASTRecordLayout::getNextOffset accessor, and some doxygen comments.

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

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

==============================================================================
--- cfe/trunk/include/clang/AST/RecordLayout.h (original)
+++ cfe/trunk/include/clang/AST/RecordLayout.h Mon May  4 16:00:40 2009
@@ -72,14 +72,24 @@
   void operator=(const ASTRecordLayout&); // DO NOT IMPLEMENT
 public:
   
+  /// getAlignment - Get the record alignment in bits.
   unsigned getAlignment() const { return Alignment; }
+
+  /// getSize - Get the record size in bits.
   uint64_t getSize() const { return Size; }
   
+  /// getFieldOffset - Get the offset of the given field index, in
+  /// bits.
   uint64_t getFieldOffset(unsigned FieldNo) const {
     assert (FieldNo < FieldCount && "Invalid Field No");
     return FieldOffsets[FieldNo];
   }
     
+  /// getNextOffset - Get the next available (unused) offset in the
+  /// structure, in bits.
+  uint64_t getNextOffset() const {
+    return NextOffset;
+  }
 };
 
 }  // end namespace clang





More information about the cfe-commits mailing list