summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object/Binary.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2018-03-07 18:58:33 +0000
committerZachary Turner <zturner@google.com>2018-03-07 18:58:33 +0000
commitaac28f31b3903b907dcb50ea7e4e0bbe22c944bf (patch)
treedefc819bc6512eb2d44c2019b5063cb80eb43d99 /llvm/lib/Object/Binary.cpp
parentb2da08610327d32474a931502c03f486ccbe36ac (diff)
downloadbcm5719-llvm-aac28f31b3903b907dcb50ea7e4e0bbe22c944bf.tar.gz
bcm5719-llvm-aac28f31b3903b907dcb50ea7e4e0bbe22c944bf.zip
Update a few switch statements to handle file_magic::pdb.
This fixes a couple of warnings. llvm-svn: 326927
Diffstat (limited to 'llvm/lib/Object/Binary.cpp')
-rw-r--r--llvm/lib/Object/Binary.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Object/Binary.cpp b/llvm/lib/Object/Binary.cpp
index c4565db459e..d7c25921ec3 100644
--- a/llvm/lib/Object/Binary.cpp
+++ b/llvm/lib/Object/Binary.cpp
@@ -75,6 +75,9 @@ Expected<std::unique_ptr<Binary>> object::createBinary(MemoryBufferRef Buffer,
return MachOUniversalBinary::create(Buffer);
case file_magic::windows_resource:
return WindowsResource::createWindowsResource(Buffer);
+ case file_magic::pdb:
+ // PDB does not support the Binary interface.
+ return errorCodeToError(object_error::invalid_file_type);
case file_magic::unknown:
case file_magic::coff_cl_gl_object:
// Unrecognized object file format.
OpenPOWER on IntegriCloud