diff --git a/include/llvm/Attributes.h b/include/llvm/Attributes.h
index ab4735f..5adbb49 100644
--- a/include/llvm/Attributes.h
+++ b/include/llvm/Attributes.h
@@ -6,10 +6,11 @@
 // License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
-//
-// This file contains the simple types necessary to represent the
-// attributes associated with functions and their calls.
-//
+///
+/// \file
+/// \brief This file contains the simple types necessary to represent the
+/// attributes associated with functions and their calls.
+///
 //===----------------------------------------------------------------------===//
 
 #ifndef LLVM_ATTRIBUTES_H
@@ -28,7 +29,8 @@
 class Type;
 
 //===----------------------------------------------------------------------===//
-/// \class Functions, function parameters, and return types can have attributes
+/// \class
+/// \brief Functions, function parameters, and return types can have attributes
 /// to indicate how they should be treated by optimizations and code
 /// generation. This class represents one of those attributes. It's light-weight
 /// and should be passed around by-value.
@@ -91,10 +93,10 @@
     ZExt                   ///< Zero extended before/after call
   };
 private:
-  AttributeImpl *Attrs;
-  Attribute(AttributeImpl *A) : Attrs(A) {}
+  AttributeImpl *pImpl;
+  Attribute(AttributeImpl *A) : pImpl(A) {}
 public:
-  Attribute() : Attrs(0) {}
+  Attribute() : pImpl(0) {}
 
   /// \brief Return a uniquified Attribute object. This takes the uniquified
   /// value from the Builder and wraps it in the Attribute class.
@@ -119,10 +121,10 @@
   unsigned getStackAlignment() const;
 
   bool operator==(const Attribute &A) const {
-    return Attrs == A.Attrs;
+    return pImpl == A.pImpl;
   }
   bool operator!=(const Attribute &A) const {
-    return Attrs != A.Attrs;
+    return pImpl != A.pImpl;
   }
 
   uint64_t Raw() const;
@@ -148,10 +150,11 @@
 };
 
 //===----------------------------------------------------------------------===//
-/// AttrBuilder - This class is used in conjunction with the Attribute::get
-/// method to create an Attribute object. The object itself is uniquified. The
-/// Builder's value, however, is not. So this can be used as a quick way to test
-/// for equality, presence of attributes, etc.
+/// \class
+/// \brief This class is used in conjunction with the Attribute::get method to
+/// create an Attribute object. The object itself is uniquified. The Builder's
+/// value, however, is not. So this can be used as a quick way to test for
+/// equality, presence of attributes, etc.
 class AttrBuilder {
   uint64_t Bits;
 public:
@@ -173,7 +176,7 @@
   /// removeAttribute - Remove the attributes from A from the builder.
   AttrBuilder &removeAttributes(const Attribute &A);
 
-  /// hasAttribute - Return true if the builder has the specified attribute.
+  /// contains - Return true if the builder has the specified attribute.
   bool hasAttribute(Attribute::AttrVal A) const;
 
   /// hasAttributes - Return true if the builder has IR-level attributes.
@@ -239,7 +242,8 @@
 };
 
 //===----------------------------------------------------------------------===//
-/// \class This is just a pair of values to associate a set of attributes with
+/// \class
+/// \brief This is just a pair of values to associate a set of attributes with
 /// an index.
 struct AttributeWithIndex {
   Attribute Attrs;  ///< The attributes that are set, or'd together.
@@ -266,7 +270,8 @@
 class AttributeSetImpl;
 
 //===----------------------------------------------------------------------===//
-/// \class This class manages the ref count for the opaque AttributeSetImpl
+/// \class
+/// \brief This class manages the ref count for the opaque AttributeSetImpl
 /// object and provides accessors for it.
 class AttributeSet {
 public:
@@ -381,6 +386,6 @@
   void dump() const;
 };
 
-} // End llvm namespace
+} // end llvm namespace
 
 #endif
diff --git a/lib/VMCore/AttributeImpl.h b/lib/VMCore/AttributeImpl.h
index 980c383..e27a029 100644
--- a/lib/VMCore/AttributeImpl.h
+++ b/lib/VMCore/AttributeImpl.h
@@ -6,10 +6,11 @@
 // License. See LICENSE.TXT for details.
 //
 //===----------------------------------------------------------------------===//
-//
-// This file defines various helper methods and classes used by LLVMContextImpl
-// for creating and managing attributes.
-//
+///
+/// \file
+/// \brief This file defines various helper methods and classes used by
+/// LLVMContextImpl for creating and managing attributes.
+///
 //===----------------------------------------------------------------------===//
 
 #ifndef LLVM_ATTRIBUTESIMPL_H
@@ -22,6 +23,11 @@
 
 class LLVMContext;
 
+//===----------------------------------------------------------------------===//
+/// \class
+/// \brief This class represents a single, uniqued attribute. That attribute
+/// could be a single enum, a tuple, or a string. It uses a discriminated union
+/// to distinguish them.
 class AttributeImpl : public FoldingSetNode {
   uint64_t Bits;                // FIXME: We will be expanding this.
 public:
@@ -47,6 +53,9 @@
   }
 };
 
+//===----------------------------------------------------------------------===//
+/// \class
+/// \brief This class represents a set of attributes.
 class AttributeSetImpl : public FoldingSetNode {
   // AttributesList is uniqued, these should not be publicly available.
   void operator=(const AttributeSetImpl &) LLVM_DELETED_FUNCTION;
diff --git a/lib/VMCore/Attributes.cpp b/lib/VMCore/Attributes.cpp
index 5bde563..d47f35a 100644
--- a/lib/VMCore/Attributes.cpp
+++ b/lib/VMCore/Attributes.cpp
@@ -62,22 +62,22 @@
 }
 
 bool Attribute::hasAttribute(AttrVal Val) const {
-  return Attrs && Attrs->hasAttribute(Val);
+  return pImpl && pImpl->hasAttribute(Val);
 }
 
 bool Attribute::hasAttributes() const {
-  return Attrs && Attrs->hasAttributes();
+  return pImpl && pImpl->hasAttributes();
 }
 
 bool Attribute::hasAttributes(const Attribute &A) const {
-  return Attrs && Attrs->hasAttributes(A);
+  return pImpl && pImpl->hasAttributes(A);
 }
 
 /// This returns the alignment field of an attribute as a byte alignment value.
 unsigned Attribute::getAlignment() const {
   if (!hasAttribute(Attribute::Alignment))
     return 0;
-  return 1U << ((Attrs->getAlignment() >> 16) - 1);
+  return 1U << ((pImpl->getAlignment() >> 16) - 1);
 }
 
 /// This returns the stack alignment field of an attribute as a byte alignment
@@ -85,11 +85,11 @@
 unsigned Attribute::getStackAlignment() const {
   if (!hasAttribute(Attribute::StackAlignment))
     return 0;
-  return 1U << ((Attrs->getStackAlignment() >> 26) - 1);
+  return 1U << ((pImpl->getStackAlignment() >> 26) - 1);
 }
 
 uint64_t Attribute::Raw() const {
-  return Attrs ? Attrs->Raw() : 0;
+  return pImpl ? pImpl->Raw() : 0;
 }
 
 Attribute Attribute::typeIncompatible(Type *Ty) {
@@ -398,8 +398,6 @@
 //===----------------------------------------------------------------------===//
 
 const AttributeSet &AttributeSet::operator=(const AttributeSet &RHS) {
-  if (AttrList == RHS.AttrList) return *this;
-
   AttrList = RHS.AttrList;
   return *this;
 }
