-
Notifications
You must be signed in to change notification settings - Fork 15.1k
[NFC][SpecialCaseList] Rename Section::SectionStr to Name
#167279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NFC][SpecialCaseList] Rename Section::SectionStr to Name
#167279
Conversation
Created using spr 1.3.7 [skip ci]
Created using spr 1.3.7
|
@llvm/pr-subscribers-llvm-support Author: Vitaly Buka (vitalybuka) ChangesFull diff: https://github.com/llvm/llvm-project/pull/167279.diff 1 Files Affected:
diff --git a/llvm/include/llvm/Support/SpecialCaseList.h b/llvm/include/llvm/Support/SpecialCaseList.h
index f904e582b5cee..8c4dc94ae54ce 100644
--- a/llvm/include/llvm/Support/SpecialCaseList.h
+++ b/llvm/include/llvm/Support/SpecialCaseList.h
@@ -197,14 +197,14 @@ class SpecialCaseList {
protected:
class Section {
public:
- Section(StringRef Str, unsigned FileIdx, bool UseGlobs)
- : SectionMatcher(UseGlobs, /*RemoveDotSlash=*/false), SectionStr(Str),
+ Section(StringRef Name, unsigned FileIdx, bool UseGlobs)
+ : SectionMatcher(UseGlobs, /*RemoveDotSlash=*/false), Name(Name),
FileIdx(FileIdx) {}
Section(Section &&) = default;
// Return name of the section, it's entire string in [].
- StringRef name() const { return SectionStr; }
+ StringRef name() const { return Name; }
// Returns true of string 'Name' matches section name interpreted as a glob.
LLVM_ABI bool matchName(StringRef Name) const;
@@ -232,7 +232,7 @@ class SpecialCaseList {
findMatcher(StringRef Prefix, StringRef Category) const;
Matcher SectionMatcher;
- StringRef SectionStr;
+ StringRef Name;
SectionEntries Entries;
unsigned FileIdx;
};
|
Created using spr 1.3.7 [skip ci]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR renames the Section::SectionStr member variable to Name for improved clarity and consistency with the class's name() accessor method.
- Renames the private member variable
SectionStrtoName - Updates the constructor parameter from
StrtoNameto match - Updates all references to use the new naming
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
No description provided.