Added the beginning of a set of rewriter functions for pretty-printing source
code as HTML.  Added a new driver option "--emit-html" to dump the source
of the main input file as HTML.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@48505 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/clang.cpp b/Driver/clang.cpp
index c004d9d..333ac60 100644
--- a/Driver/clang.cpp
+++ b/Driver/clang.cpp
@@ -63,6 +63,7 @@
   EmitLLVM,                     // Emit a .ll file.
   EmitBC,                       // Emit a .bc file.
   SerializeAST,                 // Emit a .ast file.
+  EmitHTML,                     // Translate input source into HTML.
   ASTPrint,                     // Parse ASTs and print them.
   ASTDump,                      // Parse ASTs and dump them.
   ASTView,                      // Parse ASTs and view them in Graphviz.
@@ -100,6 +101,8 @@
                         "Run parser and perform semantic analysis"),
              clEnumValN(ParsePrintCallbacks, "parse-print-callbacks",
                         "Run parser and print each callback invoked"),
+             clEnumValN(EmitHTML, "emit-html",
+                        "Output input source as HTML"),
              clEnumValN(ASTPrint, "ast-print",
                         "Build ASTs and then pretty-print them"),
              clEnumValN(ASTDump, "ast-dump",
@@ -994,7 +997,10 @@
       return CreateASTDumper();
       
     case ASTView:
-      return CreateASTViewer();      
+      return CreateASTViewer();   
+      
+    case EmitHTML:
+      return CreateHTMLPrinter();
       
     case ParseCFGDump:
     case ParseCFGView: