[NFC] Thread DeclNameRef through most of the compiler

This huge commit contains as many of the mechanical changes as possible.
This commit is contained in:
Brent Royal-Gordon
2019-12-10 19:46:10 -08:00
parent da88512eda
commit addbe3e5ed
66 changed files with 505 additions and 464 deletions

View File

@@ -40,14 +40,14 @@ namespace {
class Instrumenter : InstrumenterBase {
private:
unsigned &TmpNameIndex;
DeclName LogBeforeName;
DeclName LogAfterName;
DeclNameRef LogBeforeName;
DeclNameRef LogAfterName;
public:
Instrumenter(ASTContext &C, DeclContext *DC, unsigned &TmpNameIndex)
: InstrumenterBase(C, DC), TmpNameIndex(TmpNameIndex),
LogBeforeName((C.getIdentifier("__builtin_pc_before"))),
LogAfterName((C.getIdentifier("__builtin_pc_after"))) {}
LogBeforeName(DeclNameRef_(C.getIdentifier("__builtin_pc_before"))),
LogAfterName(DeclNameRef_(C.getIdentifier("__builtin_pc_after"))) {}
Stmt *transformStmt(Stmt *S) {
switch (S->getKind()) {
@@ -592,7 +592,7 @@ public:
return *AddedGet;
}
Added<Stmt *> buildLoggerCallWithArgs(DeclName LoggerName,
Added<Stmt *> buildLoggerCallWithArgs(DeclNameRef LoggerName,
SourceRange SR) {
if (!SR.isValid()) {
return nullptr;