summaryrefslogtreecommitdiffstats
path: root/llvm/tools/llvm-pdbutil/DiffPrinter.h
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2017-07-07 19:00:06 +0000
committerZachary Turner <zturner@google.com>2017-07-07 19:00:06 +0000
commitfe71c546e7efff551c38da95428ccf05cd35434f (patch)
treebe1bd6844cce96a5ac43d265a5cb61c855b38856 /llvm/tools/llvm-pdbutil/DiffPrinter.h
parent4eb210bdebe8303e63dd9135a7a4569d14e8b126 (diff)
downloadbcm5719-llvm-fe71c546e7efff551c38da95428ccf05cd35434f.tar.gz
bcm5719-llvm-fe71c546e7efff551c38da95428ccf05cd35434f.zip
[llvm-pdbutil] Fix build.
Some platforms require an explicit specialization of std::hash for PdbRaw_FeaturesSig. Also a test involving case sensitivity needed to be fixed. For now that particular check just accepts any path even if they're completely different. Long term we should output paths in the correct case to match MSVC. llvm-svn: 307426
Diffstat (limited to 'llvm/tools/llvm-pdbutil/DiffPrinter.h')
-rw-r--r--llvm/tools/llvm-pdbutil/DiffPrinter.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/tools/llvm-pdbutil/DiffPrinter.h b/llvm/tools/llvm-pdbutil/DiffPrinter.h
index 1235befa1c2..eeda92b072c 100644
--- a/llvm/tools/llvm-pdbutil/DiffPrinter.h
+++ b/llvm/tools/llvm-pdbutil/DiffPrinter.h
@@ -13,12 +13,23 @@
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/StringMap.h"
#include "llvm/ADT/StringRef.h"
+#include "llvm/DebugInfo/PDB/Native/RawConstants.h"
#include "llvm/Support/FormatVariadic.h"
#include "llvm/Support/raw_ostream.h"
#include <list>
#include <unordered_set>
+namespace std {
+template <> struct hash<llvm::pdb::PdbRaw_FeatureSig> {
+ typedef llvm::pdb::PdbRaw_FeatureSig argument_type;
+ typedef std::size_t result_type;
+ result_type operator()(argument_type Item) const {
+ return std::hash<uint32_t>{}(uint32_t(Item));
+ }
+};
+} // namespace std
+
namespace llvm {
namespace pdb {
OpenPOWER on IntegriCloud