mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-04 14:31:04 +01:00
Use static name resolution in Interpreter (#1022)
Co-authored-by: Jon Meow <46229924+jonmeow@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
co-authored by
Jon Meow
parent
d28e75629e
commit
c311c8849c
@@ -55,16 +55,11 @@ void Heap::Print(llvm::raw_ostream& out) const {
|
||||
llvm::ListSeparator sep;
|
||||
for (size_t i = 0; i < values_.size(); ++i) {
|
||||
out << sep;
|
||||
PrintAllocation(AllocationId(i), out);
|
||||
if (!alive_[i]) {
|
||||
out << "!!";
|
||||
}
|
||||
out << *values_[i];
|
||||
}
|
||||
}
|
||||
|
||||
void Heap::PrintAllocation(AllocationId allocation,
|
||||
llvm::raw_ostream& out) const {
|
||||
if (!alive_[allocation.index_]) {
|
||||
out << "!!";
|
||||
}
|
||||
out << *values_[allocation.index_];
|
||||
}
|
||||
|
||||
} // namespace Carbon
|
||||
|
||||
Reference in New Issue
Block a user