From 6d48faf334248edd0cf0933b86aee87dda2fbee8 Mon Sep 17 00:00:00 2001 From: Yaron Keren Date: Wed, 6 Aug 2014 20:59:09 +0000 Subject: [PATCH] getNewMemBuffer memsets the buffer to zeros, the caller don't have to initialize it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@214994 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/Support/MemoryBuffer.h | 2 +- lib/Support/MemoryBuffer.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/llvm/Support/MemoryBuffer.h b/include/llvm/Support/MemoryBuffer.h index 147be47e1c8..29833921097 100644 --- a/include/llvm/Support/MemoryBuffer.h +++ b/include/llvm/Support/MemoryBuffer.h @@ -107,7 +107,7 @@ public: StringRef BufferName = ""); /// getNewMemBuffer - Allocate a new MemoryBuffer of the specified size that - /// is completely initialized to zeros. Note that the caller should + /// is completely initialized to zeros. Note that the caller need not /// initialize the memory allocated by this method. The memory is owned by /// the MemoryBuffer object. static MemoryBuffer *getNewMemBuffer(size_t Size, StringRef BufferName = ""); diff --git a/lib/Support/MemoryBuffer.cpp b/lib/Support/MemoryBuffer.cpp index 522c365f3d5..75f25beda82 100644 --- a/lib/Support/MemoryBuffer.cpp +++ b/lib/Support/MemoryBuffer.cpp @@ -142,7 +142,7 @@ MemoryBuffer *MemoryBuffer::getNewUninitMemBuffer(size_t Size, } /// getNewMemBuffer - Allocate a new MemoryBuffer of the specified size that -/// is completely initialized to zeros. Note that the caller should +/// is completely initialized to zeros. Note that the caller need not /// initialize the memory allocated by this method. The memory is owned by /// the MemoryBuffer object. MemoryBuffer *MemoryBuffer::getNewMemBuffer(size_t Size, StringRef BufferName) {