diff options
| author | Zachary Turner <zturner@google.com> | 2017-02-03 21:22:27 +0000 |
|---|---|---|
| committer | Zachary Turner <zturner@google.com> | 2017-02-03 21:22:27 +0000 |
| commit | 5ce0f4a9de80d5eb6a524a072b455a87902c3c36 (patch) | |
| tree | 6104ad3da1d4c3f7015e32474172be95cb8ef983 /llvm/include/llvm/DebugInfo/CodeView/Formatters.h | |
| parent | 62f175f01eba850a7cfaa340fd1fd75a84074d0f (diff) | |
| download | bcm5719-llvm-5ce0f4a9de80d5eb6a524a072b455a87902c3c36.tar.gz bcm5719-llvm-5ce0f4a9de80d5eb6a524a072b455a87902c3c36.zip | |
Properly parse the TypeServer2 record.
llvm-svn: 294046
Diffstat (limited to 'llvm/include/llvm/DebugInfo/CodeView/Formatters.h')
| -rw-r--r-- | llvm/include/llvm/DebugInfo/CodeView/Formatters.h | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/llvm/include/llvm/DebugInfo/CodeView/Formatters.h b/llvm/include/llvm/DebugInfo/CodeView/Formatters.h new file mode 100644 index 00000000000..d64024c56be --- /dev/null +++ b/llvm/include/llvm/DebugInfo/CodeView/Formatters.h @@ -0,0 +1,36 @@ +//===- Formatters.h ---------------------------------------------*- C++ -*-===// +// +// The LLVM Compiler Infrastructure +// +// This file is distributed under the University of Illinois Open Source +// License. See LICENSE.TXT for details. +// +//===----------------------------------------------------------------------===// + +#ifndef LLVM_DEBUGINFO_CODEVIEW_FORMATTERS_H +#define LLVM_DEBUGINFO_CODEVIEW_FORMATTERS_H + +#include "llvm/ADT/ArrayRef.h" +#include "llvm/ADT/StringRef.h" +#include "llvm/Support/FormatAdapters.h" + +namespace llvm { +namespace codeview { +namespace detail { +class GuidAdapter final : public llvm::FormatAdapter<ArrayRef<uint8_t>> { + ArrayRef<uint8_t> Guid; + +public: + explicit GuidAdapter(ArrayRef<uint8_t> Guid); + explicit GuidAdapter(StringRef Guid); + void format(llvm::raw_ostream &Stream, StringRef Style); +}; +} + +inline detail::GuidAdapter fmt_guid(StringRef Item) { + return detail::GuidAdapter(Item); +} +} +} + +#endif |

