Coverage Report

Created: 2018-07-19 03:59

/Users/buildslave/jenkins/workspace/clang-stage2-coverage-R/llvm/include/llvm/DebugInfo/CodeView/GUID.h
Line
Count
Source (jump to first uncovered line)
1
//===- GUID.h ---------------------------------------------------*- C++ -*-===//
2
//
3
//                     The LLVM Compiler Infrastructure
4
//
5
// This file is distributed under the University of Illinois Open Source
6
// License. See LICENSE.TXT for details.
7
//
8
//===----------------------------------------------------------------------===//
9
10
#ifndef LLVM_DEBUGINFO_CODEVIEW_GUID_H
11
#define LLVM_DEBUGINFO_CODEVIEW_GUID_H
12
13
#include <cstdint>
14
#include <cstring>
15
16
namespace llvm {
17
class raw_ostream;
18
19
namespace codeview {
20
21
/// This represents the 'GUID' type from windows.h.
22
struct GUID {
23
  uint8_t Guid[16];
24
};
25
26
inline bool operator==(const GUID &LHS, const GUID &RHS) {
27
  return 0 == ::memcmp(LHS.Guid, RHS.Guid, sizeof(LHS.Guid));
28
}
29
30
inline bool operator<(const GUID &LHS, const GUID &RHS) {
31
  return ::memcmp(LHS.Guid, RHS.Guid, sizeof(LHS.Guid)) < 0;
32
}
33
34
inline bool operator<=(const GUID &LHS, const GUID &RHS) {
35
  return ::memcmp(LHS.Guid, RHS.Guid, sizeof(LHS.Guid)) <= 0;
36
}
37
38
0
inline bool operator>(const GUID &LHS, const GUID &RHS) {
39
0
  return !(LHS <= RHS);
40
0
}
41
42
0
inline bool operator>=(const GUID &LHS, const GUID &RHS) {
43
0
  return !(LHS < RHS);
44
0
}
45
46
inline bool operator!=(const GUID &LHS, const GUID &RHS) {
47
  return !(LHS == RHS);
48
}
49
50
raw_ostream &operator<<(raw_ostream &OS, const GUID &Guid);
51
52
} // namespace codeview
53
} // namespace llvm
54
55
#endif