Rearrange code to eliminate warnings
[oota-llvm.git] / include / llvm / Assembly / CachedWriter.h
index 2d4741b7f0dc50db35fb14af3ef817436bfddfc7..a2167363599cce3c8f41131ad126255be484a26c 100644 (file)
@@ -1,28 +1,30 @@
-//===-- llvm/Assembly/CachedWriter.h - Printer Accellerator ------*- C++ -*--=//
+//===-- llvm/Assembly/CachedWriter.h - Printer Accellerator -----*- C++ -*-===//
+// 
+//                     The LLVM Compiler Infrastructure
 //
-// This file defines a 'CacheWriter' class that is used to accelerate printing
+// This file was developed by the LLVM research group and is distributed under
+// the University of Illinois Open Source License. See LICENSE.TXT for details.
+// 
+//===----------------------------------------------------------------------===//
+//
+// This file defines a 'CachedWriter' class that is used to accelerate printing
 // chunks of LLVM.  This is used when a module is not being changed, but random
 // parts of it need to be printed.  This can greatly speed up printing of LLVM
 // output.
 //
 //===----------------------------------------------------------------------===//
 
-#ifndef LLVM_ASSEMBLY_CACHED_WRITER_H
-#define LLVM_ASSEMBLY_CACHED_WRITER_H
+#ifndef LLVM_ASSEMBLY_CACHEDWRITER_H
+#define LLVM_ASSEMBLY_CACHEDWRITER_H
 
 #include "llvm/Value.h"
 #include <iostream>
 
-class GlobalVariable;
-class Function;
-class FunctionArgument;
-class BasicBlock;
-class Instruction;
-class Constant;
+namespace llvm {
+
+class Module;
 class PointerType;
 class SlotCalculator;
-
-
 class AssemblyWriter;  // Internal private class
 
 class CachedWriter {
@@ -46,16 +48,13 @@ public:
   inline CachedWriter &operator<<(Value *X) {
     return *this << (const Value*)X;
   }
-  inline CachedWriter &operator<<(const Module *X) {
-    return *this << (const Value*)X;
-  }
   inline CachedWriter &operator<<(const GlobalVariable *X) {
     return *this << (const Value*)X;
   }
   inline CachedWriter &operator<<(const Function *X) {
     return *this << (const Value*)X;
   }
-  inline CachedWriter &operator<<(const FunctionArgument *X) {
+  inline CachedWriter &operator<<(const Argument *X) {
     return *this << (const Value*)X;
   }
   inline CachedWriter &operator<<(const BasicBlock *X) {
@@ -85,4 +84,6 @@ public:
   }
 };
 
+} // End llvm namespace
+
 #endif