]> granicus.if.org Git - clang/commit
Remove llvm::MemoryBuffer const_casts
authorPavel Labath <labath@google.com>
Wed, 20 Dec 2017 11:34:38 +0000 (11:34 +0000)
committerPavel Labath <labath@google.com>
Wed, 20 Dec 2017 11:34:38 +0000 (11:34 +0000)
commit0604b824fdd2e3b0c6705a4b7aabc532ebb4613e
treec21af03e5f0d59aca81934b8db0a66d769e96586
parentfdd60aee9c0ea40fa0423d6e43821f53d07961d5
Remove llvm::MemoryBuffer const_casts

Summary:
llvm has grown a WritableMemoryBuffer class, which is convertible
(inherits from) a MemoryBuffer. We can use it to avoid conts_casting the
buffer contents when we want to write to it.

Reviewers: dblaikie, rsmith

Subscribers: cfe-commits

Differential Revision: https://reviews.llvm.org/D41387

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321167 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Basic/SourceManager.cpp
lib/Lex/Preprocessor.cpp