Skip to content

Commit 0613f8b

Browse files
[clang-move] Teach getDeclarationList to return ArrayRef (NFC) (#143278)
getDeclarationList is used only for read-only access to the array. I don't think it's actually meant to return by value.
1 parent 38658b5 commit 0613f8b

File tree

1 file changed

+1
-3
lines changed
  • clang-tools-extra/clang-move

1 file changed

+1
-3
lines changed

clang-tools-extra/clang-move/Move.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,7 @@ class DeclarationReporter {
4949
bool Templated = false; // Whether the declaration is templated.
5050
};
5151

52-
const std::vector<Declaration> getDeclarationList() const {
53-
return DeclarationList;
54-
}
52+
ArrayRef<Declaration> getDeclarationList() const { return DeclarationList; }
5553

5654
private:
5755
std::vector<Declaration> DeclarationList;

0 commit comments

Comments
 (0)