[AST] Drop const from a return type (NFC) (#140665)

This commit is contained in:
Kazu Hirata
2025-05-19 21:37:28 -07:00
committed by GitHub
parent e0515c890d
commit 1fa26efeed
2 changed files with 2 additions and 2 deletions

View File

@@ -29,7 +29,7 @@ Record::Record(const RecordDecl *Decl, BaseList &&SrcBases,
VirtualBaseMap[V.Decl] = &V;
}
const std::string Record::getName() const {
std::string Record::getName() const {
std::string Ret;
llvm::raw_string_ostream OS(Ret);
Decl->getNameForDiagnostic(OS, Decl->getASTContext().getPrintingPolicy(),

View File

@@ -52,7 +52,7 @@ public:
/// Returns the underlying declaration.
const RecordDecl *getDecl() const { return Decl; }
/// Returns the name of the underlying declaration.
const std::string getName() const;
std::string getName() const;
/// Checks if the record is a union.
bool isUnion() const { return IsUnion; }
/// Checks if the record is an anonymous union.