forked from OSchip/llvm-project
[PECOFF] Rename getFinalSectionName -> getOutputSectionName.
llvm-svn: 195855
This commit is contained in:
parent
26c191aec6
commit
951dd1d411
|
@ -194,7 +194,7 @@ public:
|
|||
void setImageType(ImageType type) { _imageType = type; }
|
||||
ImageType getImageType() const { return _imageType; }
|
||||
|
||||
StringRef getFinalSectionName(StringRef sectionName) const;
|
||||
StringRef getOutputSectionName(StringRef sectionName) const;
|
||||
bool addSectionRenaming(raw_ostream &diagnostics,
|
||||
StringRef from, StringRef to);
|
||||
|
||||
|
|
|
@ -111,11 +111,11 @@ bool PECOFFLinkingContext::createImplicitFiles(
|
|||
/// executable. We have a mapping for the renaming. This method looks up the
|
||||
/// table and returns a new section name if renamed.
|
||||
StringRef
|
||||
PECOFFLinkingContext::getFinalSectionName(StringRef sectionName) const {
|
||||
PECOFFLinkingContext::getOutputSectionName(StringRef sectionName) const {
|
||||
auto it = _renamedSections.find(sectionName);
|
||||
if (it == _renamedSections.end())
|
||||
return sectionName;
|
||||
return getFinalSectionName(it->second);
|
||||
return getOutputSectionName(it->second);
|
||||
}
|
||||
|
||||
/// Adds a mapping to the section renaming table. This method will be used for
|
||||
|
|
|
@ -252,9 +252,9 @@ TEST_F(WinLinkParserTest, Include) {
|
|||
TEST_F(WinLinkParserTest, Merge) {
|
||||
EXPECT_TRUE(parse("link.exe", "/merge:.foo=.bar", "/merge:.bar=.baz",
|
||||
"a.out", nullptr));
|
||||
EXPECT_EQ(".baz", _context.getFinalSectionName(".foo"));
|
||||
EXPECT_EQ(".baz", _context.getFinalSectionName(".bar"));
|
||||
EXPECT_EQ(".abc", _context.getFinalSectionName(".abc"));
|
||||
EXPECT_EQ(".baz", _context.getOutputSectionName(".foo"));
|
||||
EXPECT_EQ(".baz", _context.getOutputSectionName(".bar"));
|
||||
EXPECT_EQ(".abc", _context.getOutputSectionName(".abc"));
|
||||
}
|
||||
|
||||
TEST_F(WinLinkParserTest, Merge_Circular) {
|
||||
|
|
Loading…
Reference in New Issue