18#ifndef LLVM_CLANG_SCALABLESTATICANALYSISFRAMEWORK_CORE_MODEL_BUILDNAMESPACE_H
19#define LLVM_CLANG_SCALABLESTATICANALYSISFRAMEWORK_CORE_MODEL_BUILDNAMESPACE_H
21#include "llvm/ADT/STLExtras.h"
22#include "llvm/ADT/StringRef.h"
23#include "llvm/Support/raw_ostream.h"
46 auto asTuple()
const {
return std::tie(Kind, Name); }
50 : Kind(Kind), Name(Name.str()) {}
65 friend llvm::raw_ostream &
operator<<(llvm::raw_ostream &OS,
79 std::vector<BuildNamespace> Namespaces;
85 : Namespaces(Namespaces) {}
88 Namespaces.push_back(N);
104 Copy.Namespaces.reserve(
Copy.Namespaces.size() +
105 Namespace.Namespaces.size());
106 llvm::append_range(
Copy.Namespaces, Namespace.Namespaces);
118 friend llvm::raw_ostream &
operator<<(llvm::raw_ostream &OS,
124llvm::raw_ostream &
operator<<(llvm::raw_ostream &OS,
Represents a single namespace in the build process.
BuildNamespace(BuildNamespaceKind Kind, llvm::StringRef Name)
bool operator<(const BuildNamespace &Other) const
friend class EntityLinker
bool operator!=(const BuildNamespace &Other) const
static BuildNamespace makeCompilationUnit(llvm::StringRef CompilationId)
Creates a BuildNamespace representing a compilation unit.
bool operator==(const BuildNamespace &Other) const
friend class SerializationFormat
friend llvm::raw_ostream & operator<<(llvm::raw_ostream &OS, const BuildNamespace &BN)
Represents a hierarchical sequence of build namespaces.
NestedBuildNamespace(const std::vector< BuildNamespace > &Namespaces)
static NestedBuildNamespace makeCompilationUnit(llvm::StringRef CompilationId)
Creates a NestedBuildNamespace representing a compilation unit.
NestedBuildNamespace()=default
NestedBuildNamespace(const BuildNamespace &N)
bool operator<(const NestedBuildNamespace &Other) const
friend class SerializationFormat
NestedBuildNamespace makeQualified(NestedBuildNamespace Namespace) const
Creates a new NestedBuildNamespace by appending additional namespace.
bool operator!=(const NestedBuildNamespace &Other) const
friend llvm::raw_ostream & operator<<(llvm::raw_ostream &OS, const NestedBuildNamespace &NBN)
bool operator==(const NestedBuildNamespace &Other) const
llvm::raw_ostream & operator<<(llvm::raw_ostream &OS, BuildNamespaceKind BNK)
@ Other
Other implicit parameter.