Subversion Repositories QNX 8.QNX8 LLVM/Clang compiler suite

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
14 pmbaty 1
//===- CodeViewYAMLSymbols.h - CodeView YAMLIO Symbol implementation ------===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
//
9
// This file defines classes for handling the YAML representation of CodeView
10
// Debug Info.
11
//
12
//===----------------------------------------------------------------------===//
13
 
14
#ifndef LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H
15
#define LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H
16
 
17
#include "llvm/DebugInfo/CodeView/CodeView.h"
18
#include "llvm/DebugInfo/CodeView/SymbolRecord.h"
19
#include "llvm/Support/Error.h"
20
#include "llvm/Support/YAMLTraits.h"
21
#include <memory>
22
 
23
namespace llvm {
24
namespace CodeViewYAML {
25
 
26
namespace detail {
27
 
28
struct SymbolRecordBase;
29
 
30
} // end namespace detail
31
 
32
struct SymbolRecord {
33
  std::shared_ptr<detail::SymbolRecordBase> Symbol;
34
 
35
  codeview::CVSymbol
36
  toCodeViewSymbol(BumpPtrAllocator &Allocator,
37
                   codeview::CodeViewContainer Container) const;
38
 
39
  static Expected<SymbolRecord> fromCodeViewSymbol(codeview::CVSymbol Symbol);
40
};
41
 
42
} // end namespace CodeViewYAML
43
} // end namespace llvm
44
 
45
LLVM_YAML_DECLARE_MAPPING_TRAITS(CodeViewYAML::SymbolRecord)
46
LLVM_YAML_IS_SEQUENCE_VECTOR(CodeViewYAML::SymbolRecord)
47
 
48
#endif // LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H