diff --git a/lld/include/lld/ReaderWriter/Simple.h b/lld/include/lld/ReaderWriter/Simple.h index 03e87836c9a2..58bab737c1d4 100644 --- a/lld/include/lld/ReaderWriter/Simple.h +++ b/lld/include/lld/ReaderWriter/Simple.h @@ -66,9 +66,9 @@ protected: atom_collection_vector _absoluteAtoms; }; -class FileToMutable : public SimpleFile { +class SimpleFileWrapper : public SimpleFile { public: - FileToMutable(const LinkingContext &context, const File &file) + SimpleFileWrapper(const LinkingContext &context, const File &file) : SimpleFile(file.path()) { for (auto definedAtom : file.defined()) _definedAtoms._atoms.push_back(std::move(definedAtom)); diff --git a/lld/lib/Passes/RoundTripNativePass.cpp b/lld/lib/Passes/RoundTripNativePass.cpp index 42e22d48d4f8..724baad4e74b 100644 --- a/lld/lib/Passes/RoundTripNativePass.cpp +++ b/lld/lib/Passes/RoundTripNativePass.cpp @@ -47,7 +47,7 @@ void RoundTripNativePass::perform(std::unique_ptr &mergedFile) { llvm_unreachable("native reader not registered or read error"); } File *objFile = _nativeFile[0].get(); - mergedFile.reset(new FileToMutable(_context, *objFile)); + mergedFile.reset(new SimpleFileWrapper(_context, *objFile)); llvm::sys::fs::remove(tmpNativeFile.str()); } diff --git a/lld/lib/Passes/RoundTripYAMLPass.cpp b/lld/lib/Passes/RoundTripYAMLPass.cpp index a01753a44d95..ba9926a1f224 100644 --- a/lld/lib/Passes/RoundTripYAMLPass.cpp +++ b/lld/lib/Passes/RoundTripYAMLPass.cpp @@ -46,6 +46,6 @@ void RoundTripYAMLPass::perform(std::unique_ptr &mergedFile) { llvm_unreachable("yaml reader not registered or read error"); } File *objFile = _yamlFile[0].get(); - mergedFile.reset(new FileToMutable(_context, *objFile)); + mergedFile.reset(new SimpleFileWrapper(_context, *objFile)); llvm::sys::fs::remove(tmpYAMLFile.str()); }