Revert "Revert "[ptr-traits] Implement the base pointer traits using the actual""
[oota-llvm.git] / include / llvm / Support / Options.h
index 1e387a8353f391b936652d65960a8d84e023f3c7..7b61b2308f575fc350d211bbb14cac46c31dd92b 100644 (file)
@@ -34,6 +34,9 @@
 ///
 //===----------------------------------------------------------------------===//
 
+#ifndef LLVM_SUPPORT_OPTIONS_H
+#define LLVM_SUPPORT_OPTIONS_H
+
 #include "llvm/ADT/DenseMap.h"
 #include "llvm/Support/CommandLine.h"
 
@@ -58,7 +61,7 @@ char OptionKey<ValT, Base, Mem>::ID = 0;
 /// The OptionRegistry is responsible for managing lifetimes of the options and
 /// provides interfaces for option registration and reading values from options.
 /// This object is a singleton, only one instance should ever exist so that all
-/// options are registered in teh same place.
+/// options are registered in the same place.
 class OptionRegistry {
 private:
   DenseMap<void *, cl::Option *> Options;
@@ -68,7 +71,7 @@ private:
   /// \param Key unique key for option
   /// \param O option to map to \p Key
   ///
-  /// Allocated cl::Options are owened by the OptionRegistry and are deallocated
+  /// Allocated cl::Options are owned by the OptionRegistry and are deallocated
   /// on destruction or removal
   void addOption(void *Key, cl::Option *O);
 
@@ -88,7 +91,7 @@ public:
   /// Options are keyed off the template parameters to generate unique static
   /// characters. The template parameters are (1) the type of the data the
   /// option stores (\p ValT), the class that will read the option (\p Base),
-  /// and the memeber that the class will store the data into (\p Mem).
+  /// and the member that the class will store the data into (\p Mem).
   template <typename ValT, typename Base, ValT(Base::*Mem)>
   static void registerOption(const char *ArgStr, const char *Desc,
                              const ValT &InitValue) {
@@ -113,3 +116,5 @@ public:
 };
 
 } // namespace llvm
+
+#endif