LLVM
17.0.0git
include
llvm
DebugInfo
CodeView
CodeViewError.h
Go to the documentation of this file.
1
//===- CodeViewError.h - Error extensions for CodeView ----------*- C++ -*-===//
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
#ifndef LLVM_DEBUGINFO_CODEVIEW_CODEVIEWERROR_H
10
#define LLVM_DEBUGINFO_CODEVIEW_CODEVIEWERROR_H
11
12
#include "
llvm/Support/Error.h
"
13
14
namespace
llvm
{
15
namespace
codeview {
16
enum class
cv_error_code
{
17
unspecified
= 1,
18
insufficient_buffer
,
19
operation_unsupported
,
20
corrupt_record
,
21
no_records
,
22
unknown_member_record
,
23
};
24
}
// namespace codeview
25
}
// namespace llvm
26
27
namespace
std
{
28
template
<>
29
struct
is_error_code_enum<
llvm
::
codeview::cv_error_code
> : std::true_type {};
30
}
// namespace std
31
32
namespace
llvm
{
33
namespace
codeview {
34
const
std::error_category &
CVErrorCategory
();
35
36
inline
std::error_code
make_error_code
(
cv_error_code
E
) {
37
return
std::error_code(
static_cast<
int
>
(
E
),
CVErrorCategory
());
38
}
39
40
/// Base class for errors originating when parsing raw PDB files
41
class
CodeViewError
:
public
ErrorInfo
<CodeViewError, StringError> {
42
public
:
43
using
ErrorInfo
<
CodeViewError
,
44
StringError
>
::ErrorInfo
;
// inherit constructors
45
CodeViewError
(
const
Twine
&
S
) :
ErrorInfo
(
S
,
cv_error_code
::
unspecified
) {}
46
static
char
ID
;
47
};
48
49
}
// namespace codeview
50
}
// namespace llvm
51
52
#endif
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition:
AddressRanges.h:18
llvm::codeview::cv_error_code::operation_unsupported
@ operation_unsupported
llvm::codeview::CodeViewError
Base class for errors originating when parsing raw PDB files.
Definition:
CodeViewError.h:41
Error.h
llvm::codeview::cv_error_code::insufficient_buffer
@ insufficient_buffer
llvm::codeview::make_error_code
std::error_code make_error_code(cv_error_code E)
Definition:
CodeViewError.h:36
llvm::codeview::CVErrorCategory
const std::error_category & CVErrorCategory()
Definition:
CodeViewError.cpp:44
E
static GCRegistry::Add< CoreCLRGC > E("coreclr", "CoreCLR-compatible GC")
llvm::codeview::cv_error_code::no_records
@ no_records
llvm::codeview::CodeViewError::ID
static char ID
Definition:
CodeViewError.h:46
llvm::codeview::cv_error_code
cv_error_code
Definition:
CodeViewError.h:16
llvm::codeview::CodeViewError::CodeViewError
CodeViewError(const Twine &S)
Definition:
CodeViewError.h:45
llvm::StringError
This class wraps a string in an Error.
Definition:
Error.h:1223
llvm::ErrorInfo
Base class for user error types.
Definition:
Error.h:348
S
add sub stmia L5 ldr r0 bl L_printf $stub Instead of a and a wouldn t it be better to do three moves *Return an aggregate type is even return S
Definition:
README.txt:210
llvm::Twine
Twine - A lightweight data structure for efficiently representing the concatenation of temporary valu...
Definition:
Twine.h:81
std
Definition:
BitVector.h:851
llvm::codeview::cv_error_code::corrupt_record
@ corrupt_record
llvm::codeview::cv_error_code::unknown_member_record
@ unknown_member_record
llvm::codeview::cv_error_code::unspecified
@ unspecified
Generated on Sat Jan 28 2023 08:45:45 for LLVM by
1.8.17