Change some terminology in SourceLocation: instead of referring to

the "physical" location of tokens, refer to the "spelling" location.
This is more concrete and useful, tokens aren't really physical objects!

llvm-svn: 62309
This commit is contained in:
Chris Lattner
2009-01-16 07:00:02 +00:00
parent 2d9e40ed24
commit 53e384f633
14 changed files with 123 additions and 120 deletions

View File

@@ -358,13 +358,13 @@ void LiveVariables::dumpLiveness(const ValTy& V, SourceManager& SM) const {
for (AnalysisDataTy::decl_iterator I = AD.begin_decl(),
E = AD.end_decl(); I!=E; ++I)
if (V.getDeclBit(I->second)) {
SourceLocation PhysLoc = SM.getPhysicalLoc(I->first->getLocation());
SourceLocation SpellingLoc = SM.getSpellingLoc(I->first->getLocation());
fprintf(stderr, " %s <%s:%u:%u>\n",
I->first->getIdentifier()->getName(),
SM.getSourceName(PhysLoc),
SM.getLineNumber(PhysLoc),
SM.getColumnNumber(PhysLoc));
SM.getSourceName(SpellingLoc),
SM.getLineNumber(SpellingLoc),
SM.getColumnNumber(SpellingLoc));
}
}