[cfe-commits] r74194 - /cfe/trunk/lib/Basic/SourceManager.cpp
Argiris Kirtzidis
akyrtzi at gmail.com
Thu Jun 25 11:22:16 PDT 2009
Author: akirtzidis
Date: Thu Jun 25 13:22:16 2009
New Revision: 74194
URL: http://llvm.org/viewvc/llvm-project?rev=74194&view=rev
Log:
Fix column checking for SourceManager::getLocation().
Modified:
cfe/trunk/lib/Basic/SourceManager.cpp
Modified: cfe/trunk/lib/Basic/SourceManager.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/SourceManager.cpp?rev=74194&r1=74193&r2=74194&view=diff
==============================================================================
--- cfe/trunk/lib/Basic/SourceManager.cpp (original)
+++ cfe/trunk/lib/Basic/SourceManager.cpp Thu Jun 25 13:22:16 2009
@@ -943,7 +943,7 @@
return SourceLocation();
unsigned FilePos = Content->SourceLineCache[Line - 1];
- const char *Buf = Content->getBuffer()->getBufferStart();
+ const char *Buf = Content->getBuffer()->getBufferStart() + FilePos;
unsigned BufLength = Content->getBuffer()->getBufferEnd() - Buf;
unsigned i = 0;
More information about the cfe-commits
mailing list