1 //===- CodeViewYAMLSymbols.h - CodeView YAMLIO Symbol implementation ------===//
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
7 //===----------------------------------------------------------------------===//
9 // This file defines classes for handling the YAML representation of CodeView
12 //===----------------------------------------------------------------------===//
14 #ifndef LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H
15 #define LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H
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"
24 namespace CodeViewYAML
{
28 struct SymbolRecordBase
;
30 } // end namespace detail
33 std::shared_ptr
<detail::SymbolRecordBase
> Symbol
;
36 toCodeViewSymbol(BumpPtrAllocator
&Allocator
,
37 codeview::CodeViewContainer Container
) const;
39 static Expected
<SymbolRecord
> fromCodeViewSymbol(codeview::CVSymbol Symbol
);
42 } // end namespace CodeViewYAML
43 } // end namespace llvm
45 LLVM_YAML_DECLARE_MAPPING_TRAITS(CodeViewYAML::SymbolRecord
)
46 LLVM_YAML_IS_SEQUENCE_VECTOR(CodeViewYAML::SymbolRecord
)
48 #endif // LLVM_OBJECTYAML_CODEVIEWYAMLSYMBOLS_H