Coverage Report

Created: 2018-07-19 20:53

/Users/buildslave/jenkins/workspace/clang-stage2-coverage-R/llvm/tools/clang/include/clang/AST/MangleNumberingContext.h
Line
Count
Source
1
//=== MangleNumberingContext.h - Context for mangling numbers ---*- 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
//  This file defines the LambdaBlockMangleContext interface, which keeps track
11
//  of the Itanium C++ ABI mangling numbers for lambda expressions and block
12
//  literals.
13
//
14
//===----------------------------------------------------------------------===//
15
#ifndef LLVM_CLANG_AST_MANGLENUMBERINGCONTEXT_H
16
#define LLVM_CLANG_AST_MANGLENUMBERINGCONTEXT_H
17
18
#include "clang/Basic/LLVM.h"
19
#include "llvm/ADT/IntrusiveRefCntPtr.h"
20
21
namespace clang {
22
23
class BlockDecl;
24
class CXXMethodDecl;
25
class IdentifierInfo;
26
class TagDecl;
27
class Type;
28
class VarDecl;
29
30
/// Keeps track of the mangled names of lambda expressions and block
31
/// literals within a particular context.
32
class MangleNumberingContext {
33
public:
34
4.51k
  virtual ~MangleNumberingContext() {}
35
36
  /// Retrieve the mangling number of a new lambda expression with the
37
  /// given call operator within this context.
38
  virtual unsigned getManglingNumber(const CXXMethodDecl *CallOperator) = 0;
39
40
  /// Retrieve the mangling number of a new block literal within this
41
  /// context.
42
  virtual unsigned getManglingNumber(const BlockDecl *BD) = 0;
43
44
  /// Static locals are numbered by source order.
45
  virtual unsigned getStaticLocalNumber(const VarDecl *VD) = 0;
46
47
  /// Retrieve the mangling number of a static local variable within
48
  /// this context.
49
  virtual unsigned getManglingNumber(const VarDecl *VD,
50
                                     unsigned MSLocalManglingNumber) = 0;
51
52
  /// Retrieve the mangling number of a static local variable within
53
  /// this context.
54
  virtual unsigned getManglingNumber(const TagDecl *TD,
55
                                     unsigned MSLocalManglingNumber) = 0;
56
};
57
58
} // end namespace clang
59
#endif