[llvm] r347824 - [TextAPI] TBD Reader/Writer (bot fixes)

Juergen Ributzka via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 28 17:55:57 PST 2018


Author: ributzka
Date: Wed Nov 28 17:55:57 2018
New Revision: 347824

URL: http://llvm.org/viewvc/llvm-project?rev=347824&view=rev
Log:
[TextAPI] TBD Reader/Writer (bot fixes)

Trying if switching from a vector to an array will appeas the bots.

Modified:
    llvm/trunk/include/llvm/TextAPI/MachO/InterfaceFile.h
    llvm/trunk/unittests/TextAPI/TextStubV1Tests.cpp
    llvm/trunk/unittests/TextAPI/TextStubV2Tests.cpp

Modified: llvm/trunk/include/llvm/TextAPI/MachO/InterfaceFile.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/TextAPI/MachO/InterfaceFile.h?rev=347824&r1=347823&r2=347824&view=diff
==============================================================================
--- llvm/trunk/include/llvm/TextAPI/MachO/InterfaceFile.h (original)
+++ llvm/trunk/include/llvm/TextAPI/MachO/InterfaceFile.h Wed Nov 28 17:55:57 2018
@@ -155,7 +155,7 @@ public:
   /// This is used by the YAML writer to identify the specification it should
   /// use for writing the file.
   ///
-  /// \param Type The file type.
+  /// \param Kind The file type.
   void setFileType(FileType Kind) { FileKind = Kind; }
 
   /// Get the file type.
@@ -263,7 +263,7 @@ public:
 
   /// Add a re-exported library.
   ///
-  /// \param Name The name of the library to re-export.
+  /// \param InstallName The name of the library to re-export.
   /// \param Architectures The set of architecture for which this applies.
   void addReexportedLibrary(StringRef InstallName,
                             ArchitectureSet Architectures);

Modified: llvm/trunk/unittests/TextAPI/TextStubV1Tests.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/TextAPI/TextStubV1Tests.cpp?rev=347824&r1=347823&r2=347824&view=diff
==============================================================================
--- llvm/trunk/unittests/TextAPI/TextStubV1Tests.cpp (original)
+++ llvm/trunk/unittests/TextAPI/TextStubV1Tests.cpp Wed Nov 28 17:55:57 2018
@@ -23,7 +23,7 @@ inline bool operator<(const ExportedSymb
   return std::get<1>(lhs) < std::get<1>(rhs);
 }
 
-static ExportedSymbolSeq TBDv1Symbols({
+static ExportedSymbol TBDv1Symbols[] = {
     {SymbolKind::GlobalSymbol, "$ld$hide$os9.0$_sym1", false, false},
     {SymbolKind::GlobalSymbol, "_sym1", false, false},
     {SymbolKind::GlobalSymbol, "_sym2", false, false},
@@ -42,7 +42,7 @@ static ExportedSymbolSeq TBDv1Symbols({
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar1", false, false},
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar2", false, false},
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar3", false, false},
-});
+};
 
 namespace TBDv1 {
 
@@ -105,8 +105,9 @@ TEST(TBDv1, ReadFile) {
   }
   llvm::sort(Exports.begin(), Exports.end());
 
-  EXPECT_EQ(TBDv1Symbols.size(), Exports.size());
-  EXPECT_TRUE(std::equal(Exports.begin(), Exports.end(), TBDv1Symbols.begin()));
+  EXPECT_EQ(sizeof(TBDv1Symbols) / sizeof(ExportedSymbol), Exports.size());
+  EXPECT_TRUE(
+      std::equal(Exports.begin(), Exports.end(), std::begin(TBDv1Symbols)));
 }
 
 TEST(TBDv1, ReadFile2) {

Modified: llvm/trunk/unittests/TextAPI/TextStubV2Tests.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/unittests/TextAPI/TextStubV2Tests.cpp?rev=347824&r1=347823&r2=347824&view=diff
==============================================================================
--- llvm/trunk/unittests/TextAPI/TextStubV2Tests.cpp (original)
+++ llvm/trunk/unittests/TextAPI/TextStubV2Tests.cpp Wed Nov 28 17:55:57 2018
@@ -23,7 +23,7 @@ inline bool operator<(const ExportedSymb
   return std::get<1>(lhs) < std::get<1>(rhs);
 }
 
-static ExportedSymbolSeq TBDv2Symbols({
+static ExportedSymbol TBDv2Symbols[] = {
     {SymbolKind::GlobalSymbol, "$ld$hide$os9.0$_sym1", false, false},
     {SymbolKind::GlobalSymbol, "_sym1", false, false},
     {SymbolKind::GlobalSymbol, "_sym2", false, false},
@@ -42,7 +42,7 @@ static ExportedSymbolSeq TBDv2Symbols({
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar1", false, false},
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar2", false, false},
     {SymbolKind::ObjectiveCInstanceVariable, "class1._ivar3", false, false},
-});
+};
 
 namespace TBDv2 {
 
@@ -107,8 +107,9 @@ TEST(TBDv2, ReadFile) {
   }
   llvm::sort(Exports.begin(), Exports.end());
 
-  EXPECT_EQ(TBDv2Symbols.size(), Exports.size());
-  EXPECT_TRUE(std::equal(Exports.begin(), Exports.end(), TBDv2Symbols.begin()));
+  EXPECT_EQ(sizeof(TBDv2Symbols) / sizeof(ExportedSymbol), Exports.size());
+  EXPECT_TRUE(
+      std::equal(Exports.begin(), Exports.end(), std::begin(TBDv2Symbols)));
 }
 
 TEST(TBDv2, ReadFile2) {




More information about the llvm-commits mailing list