Skip to content

Commit 6b840ce

Browse files
committed
[clang][ssaf] Add doc comments to makeQualified methods
1 parent 3ad2d3d commit 6b840ce

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

clang/include/clang/Analysis/Scalable/Model/BuildNamespace.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,10 @@ class NestedBuildNamespace {
6161

6262
static NestedBuildNamespace makeTU(llvm::StringRef CompilationId);
6363

64-
NestedBuildNamespace makeQualified(NestedBuildNamespace Namespace) {
64+
/// Creates a new NestedBuildNamespace by appending additional namespace.
65+
///
66+
/// \param Namespace The namespace to append.
67+
NestedBuildNamespace makeQualified(NestedBuildNamespace Namespace) const {
6568
auto Copy = *this;
6669
Copy.Namespaces.reserve(Copy.Namespaces.size() + Namespace.Namespaces.size());
6770
llvm::append_range(Copy.Namespaces, Namespace.Namespaces);

clang/include/clang/Analysis/Scalable/Model/EntityName.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,10 @@ class EntityName {
3434
bool operator!=(const EntityName& Other) const;
3535
bool operator<(const EntityName& Other) const;
3636

37-
EntityName makeQualified(NestedBuildNamespace Namespace);
37+
/// Creates a new EntityName with additional build namespace qualification.
38+
///
39+
/// \param Namespace The namespace steps to append to this entity's namespace.
40+
EntityName makeQualified(NestedBuildNamespace Namespace) const;
3841

3942
friend class LinkUnitResolution;
4043
friend class SerializationFormat;

clang/lib/Analysis/Scalable/Model/EntityName.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ bool EntityName::operator<(const EntityName& Other) const {
3232
return Namespace < Other.Namespace;
3333
}
3434

35-
EntityName EntityName::makeQualified(NestedBuildNamespace Namespace) {
35+
EntityName EntityName::makeQualified(NestedBuildNamespace Namespace) const {
3636
auto Copy = *this;
3737
Copy.Namespace = Copy.Namespace.makeQualified(Namespace);
3838

0 commit comments

Comments
 (0)