Skip to content

Commit 21d8085

Browse files
committed
[clang][Interp][NFC] Rename DummyParams to DummyVariables
We create dummy descriptors for variables other than parameters these days.
1 parent 2421e76 commit 21d8085

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

clang/lib/AST/Interp/Program.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ std::optional<unsigned> Program::getOrCreateGlobal(const ValueDecl *VD,
145145

146146
std::optional<unsigned> Program::getOrCreateDummy(const ValueDecl *VD) {
147147
// Dedup blocks since they are immutable and pointers cannot be compared.
148-
if (auto It = DummyParams.find(VD); It != DummyParams.end())
148+
if (auto It = DummyVariables.find(VD); It != DummyVariables.end())
149149
return It->second;
150150

151151
// Create dummy descriptor.
@@ -158,7 +158,7 @@ std::optional<unsigned> Program::getOrCreateDummy(const ValueDecl *VD) {
158158
G->block()->invokeCtor();
159159

160160
Globals.push_back(G);
161-
DummyParams[VD] = I;
161+
DummyVariables[VD] = I;
162162
return I;
163163
}
164164

clang/lib/AST/Interp/Program.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ class Program final {
208208
llvm::DenseMap<const RecordDecl *, Record *> Records;
209209

210210
/// Dummy parameter to generate pointers from.
211-
llvm::DenseMap<const ValueDecl *, unsigned> DummyParams;
211+
llvm::DenseMap<const ValueDecl *, unsigned> DummyVariables;
212212

213213
/// Creates a new descriptor.
214214
template <typename... Ts>

0 commit comments

Comments
 (0)