Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[lldb] Remove SupportFile::Update and use the original Checksum #95623

Merged
merged 1 commit into from
Jun 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions lldb/include/lldb/Utility/SupportFile.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,6 @@ class SupportFile {
/// Materialize the file to disk and return the path to that temporary file.
virtual const FileSpec &Materialize() { return m_file_spec; }

/// Change the file name.
void Update(const FileSpec &file_spec) { m_file_spec = file_spec; }

protected:
FileSpec m_file_spec;
Checksum m_checksum;
Expand Down
6 changes: 4 additions & 2 deletions lldb/source/Symbol/LineEntry.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,9 @@ void LineEntry::ApplyFileMappings(lldb::TargetSP target_sp) {
if (target_sp) {
// Apply any file remappings to our file.
if (auto new_file_spec = target_sp->GetSourcePathMap().FindFile(
original_file_sp->GetSpecOnly()))
file_sp->Update(*new_file_spec);
original_file_sp->GetSpecOnly())) {
file_sp = std::make_shared<SupportFile>(*new_file_spec,
original_file_sp->GetChecksum());
}
}
}
Loading