Centralize where we update the source file contents in SourceManager::GetFile() in...
authorGreg Clayton <gclayton@apple.com>
Wed, 29 Jul 2015 18:37:25 +0000 (18:37 +0000)
committerGreg Clayton <gclayton@apple.com>
Wed, 29 Jul 2015 18:37:25 +0000 (18:37 +0000)
commit0d5b0a8a786e3d656d76a679be5ec8ca31125155
tree080d7ea75218ea4b666e331de3e442c4ac6af8d1
parent1e33bbecb94854ea1d648ad54c9a31a9d353f266
Centralize where we update the source file contents in SourceManager::GetFile() in case APIs are called that don't update the source.

The following functions were the only functions that updates the source file:

SourceManager::File::DisplaySourceLines()
SourceManager::File::FindLinesMatchingRegex()

But there we API calls that were using the SourceManager::File and asking it questions, like "is line 12 valid" and that might respond incorrectly if the source file had been updated.

<rdar://problem/21269402>

llvm-svn: 243551
lldb/include/lldb/Core/SourceManager.h
lldb/source/Core/SourceManager.cpp