r189344 - Adding const buffer iterator generators to Rewriter
Edwin Vane
edwin.vane at intel.com
Tue Aug 27 06:00:34 PDT 2013
Author: revane
Date: Tue Aug 27 08:00:34 2013
New Revision: 189344
URL: http://llvm.org/viewvc/llvm-project?rev=189344&view=rev
Log:
Adding const buffer iterator generators to Rewriter
Modified:
cfe/trunk/include/clang/Rewrite/Core/Rewriter.h
Modified: cfe/trunk/include/clang/Rewrite/Core/Rewriter.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Rewrite/Core/Rewriter.h?rev=189344&r1=189343&r2=189344&view=diff
==============================================================================
--- cfe/trunk/include/clang/Rewrite/Core/Rewriter.h (original)
+++ cfe/trunk/include/clang/Rewrite/Core/Rewriter.h Tue Aug 27 08:00:34 2013
@@ -149,6 +149,7 @@ public:
};
typedef std::map<FileID, RewriteBuffer>::iterator buffer_iterator;
+ typedef std::map<FileID, RewriteBuffer>::const_iterator const_buffer_iterator;
explicit Rewriter(SourceManager &SM, const LangOptions &LO)
: SourceMgr(&SM), LangOpts(&LO) {}
@@ -282,6 +283,8 @@ public:
// Iterators over rewrite buffers.
buffer_iterator buffer_begin() { return RewriteBuffers.begin(); }
buffer_iterator buffer_end() { return RewriteBuffers.end(); }
+ const_buffer_iterator buffer_begin() const { return RewriteBuffers.begin(); }
+ const_buffer_iterator buffer_end() const { return RewriteBuffers.end(); }
/// overwriteChangedFiles - Save all changed files to disk.
///
More information about the cfe-commits
mailing list