disuade people from using ostream.
authorChris Lattner <sabre@nondot.org>
Sun, 23 Aug 2009 21:53:47 +0000 (21:53 +0000)
committerChris Lattner <sabre@nondot.org>
Sun, 23 Aug 2009 21:53:47 +0000 (21:53 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79866 91177308-0d34-0410-b5e6-96231b3b80d8

docs/CodingStandards.html

index ff707f3a84fb263166f26686e700f29877207674..894521650a675bd829fde1a31001ef653d0b7463 100644 (file)
@@ -990,12 +990,14 @@ library. There are two problems with this:</p>
 </ol>
 
 <p>Note that using the other stream headers (<tt>&lt;sstream&gt;</tt> for
-example) is allowed normally, it is just <tt>&lt;iostream&gt;</tt> that is
-causing problems.</p>
-
-<p>In addition, new code should always
-use <a href="#ll_raw_ostream"><tt>raw_ostream</tt></a> or
-the <tt>llvm::MemoryBuffer</tt> API (for reading in files).</p>
+example) is not problematic in this regard (just <tt>&lt;iostream&gt;</tt>).
+However, raw_ostream provides various APIs that are better performing for almost
+every use than std::ostream style APIs, so you should just use it for new
+code.</p>
+
+<p><b>New code should always
+use <a href="#ll_raw_ostream"><tt>raw_ostream</tt></a> for writing, or
+the <tt>llvm::MemoryBuffer</tt> API for reading files.</b></p>
 
 </div>