Make PDBFile store an msf::Layout.
Previously it was storing all the fields of an msf::Layout as
separate members. This is a trivial cleanup to make it store
an msf::Layout directly. This makes the code more readable
since it becomes clear which fields of PDBFile are actually the
msf specific layout information in a sea of other bookkeeping
fields.
llvm-svn: 276460
diff --git a/llvm/lib/DebugInfo/PDB/Raw/PDBFileBuilder.cpp b/llvm/lib/DebugInfo/PDB/Raw/PDBFileBuilder.cpp
index 6312cc2..49bcb2f 100644
--- a/llvm/lib/DebugInfo/PDB/Raw/PDBFileBuilder.cpp
+++ b/llvm/lib/DebugInfo/PDB/Raw/PDBFileBuilder.cpp
@@ -76,11 +76,7 @@
return ExpectedLayout.takeError();
auto File = llvm::make_unique<PDBFile>(std::move(PdbFileBuffer), Allocator);
- const msf::Layout &L = *ExpectedLayout;
- File->StreamMap = L.StreamMap;
- File->StreamSizes = L.StreamSizes;
- File->DirectoryBlocks = L.DirectoryBlocks;
- File->SB = L.SB;
+ File->MsfLayout = *ExpectedLayout;
if (Info) {
auto ExpectedInfo = Info->build(*File);