aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Support
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-08-13 15:44:52 +0000
committerDan Gohman <gohman@apple.com>2009-08-13 15:44:52 +0000
commit072828e99bb310b69349dd1c0c1701f6ff655e02 (patch)
tree454bfbd24e64505c541c1355a0ced1e5c09ac0c3 /include/llvm/Support
parent7efa530000dcac8292d83b9ac3557b3ff7e4e7da (diff)
downloadexternal_llvm-072828e99bb310b69349dd1c0c1701f6ff655e02.zip
external_llvm-072828e99bb310b69349dd1c0c1701f6ff655e02.tar.gz
external_llvm-072828e99bb310b69349dd1c0c1701f6ff655e02.tar.bz2
Fix the buffer handling logic so that write_impl is always called with
a full buffer, rather than often being called with a slightly-less-than-full buffer. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78907 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Support')
-rw-r--r--include/llvm/Support/raw_ostream.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/llvm/Support/raw_ostream.h b/include/llvm/Support/raw_ostream.h
index f7fbe21..58de3e8 100644
--- a/include/llvm/Support/raw_ostream.h
+++ b/include/llvm/Support/raw_ostream.h
@@ -261,6 +261,10 @@ private:
/// non-empty. This outputs the currently buffered data and resets
/// the buffer to empty.
void flush_nonempty();
+
+ /// copy_to_buffer - Copy data into the buffer. Size must not be
+ /// greater than the number of unused bytes in the buffer.
+ void copy_to_buffer(const char *Ptr, size_t Size);
};
//===----------------------------------------------------------------------===//