[clang-tools-extra] r228692 - Renamed module.map to module.modulemap.

John Thompson John.Thompson.JTSoftware at gmail.com
Tue Feb 10 06:29:16 PST 2015


Author: jtsoftware
Date: Tue Feb 10 08:29:16 2015
New Revision: 228692

URL: http://llvm.org/viewvc/llvm-project?rev=228692&view=rev
Log:
Renamed module.map to module.modulemap.

Added:
    clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.modulemap
    clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.modulemap
Removed:
    clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.map
    clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.map
Modified:
    clang-tools-extra/trunk/docs/module-map-checker.rst
    clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.cpp
    clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.h
    clang-tools-extra/trunk/test/module-map-checker/includes.module-map-checker
    clang-tools-extra/trunk/test/module-map-checker/main-test.module-map-checker

Modified: clang-tools-extra/trunk/docs/module-map-checker.rst
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/docs/module-map-checker.rst?rev=228692&r1=228691&r2=228692&view=diff
==============================================================================
--- clang-tools-extra/trunk/docs/module-map-checker.rst (original)
+++ clang-tools-extra/trunk/docs/module-map-checker.rst Tue Feb 10 08:29:16 2015
@@ -26,7 +26,7 @@ can be included on the command line afte
 
 Warning message have the form::
 
-  warning: module.map does not account for file: header.h
+  warning: module.modulemap does not account for file: header.h
 
 Note that for the case of the module map referencing a file that does
 not exist, the module map parser in Clang will display an error message.
@@ -73,7 +73,7 @@ Module-Map-Checker Command Line Options
 .. option:: -I (include path)
 
   Look at headers only in this directory tree.
-  Must be a path relative to the module.map file.
+  Must be a path relative to the module.modulemap file.
   There can be multiple ``-I`` options, for when the
   module map covers multiple directories, and
   excludes higher or sibling directories not

Modified: clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.cpp?rev=228692&r1=228691&r2=228692&view=diff
==============================================================================
--- clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.cpp (original)
+++ clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.cpp Tue Feb 10 08:29:16 2015
@@ -16,7 +16,7 @@
 // Options:
 //
 //    -I(include path)      Look at headers only in this directory tree.
-//                          Must be a path relative to the module.map file.
+//                          Must be a path relative to the module.modulemap file.
 //                          There can be multiple -I options, for when the
 //                          module map covers multiple directories, and
 //                          excludes higher or sibling directories not
@@ -52,7 +52,7 @@
 //
 // Warning message have the form:
 //
-//  warning: module.map does not account for file: Level3A.h
+//  warning: module.modulemap does not account for file: Level3A.h
 //
 // Note that for the case of the module map referencing a file that does
 // not exist, the module map parser in Clang will (at the time of this
@@ -100,7 +100,7 @@ namespace sys = llvm::sys;
 // Option for include paths.
 static cl::list<std::string>
 IncludePaths("I", cl::desc("Include path."
-                           " Must be relative to module.map file."),
+                           " Must be relative to module.modulemap file."),
              cl::ZeroOrMore, cl::value_desc("path"));
 
 // Option for dumping the parsed module map.
@@ -108,11 +108,11 @@ static cl::opt<bool>
 DumpModuleMap("dump-module-map", cl::init(false),
               cl::desc("Dump the parsed module map information."));
 
-// Option for module.map path.
+// Option for module.modulemap path.
 static cl::opt<std::string>
-ModuleMapPath(cl::Positional, cl::init("module.map"),
-              cl::desc("<The module.map file path."
-                       " Uses module.map in current directory if omitted.>"));
+ModuleMapPath(cl::Positional, cl::init("module.modulemap"),
+              cl::desc("<The module.modulemap file path."
+                " Uses module.modulemap in current directory if omitted.>"));
 
 // Collect all other arguments, which will be passed to the front end.
 static cl::list<std::string>
@@ -235,10 +235,10 @@ ModuleMapChecker *ModuleMapChecker::crea
 }
 
 // Do checks.
-// Starting from the directory of the module.map file,
+// Starting from the directory of the module.modulemap file,
 // Find all header files, optionally looking only at files
 // covered by the include path options, and compare against
-// the headers referenced by the module.map file.
+// the headers referenced by the module.modulemap file.
 // Display warnings for unaccounted-for header files.
 // Returns error_code of 0 if there were no errors or warnings, 1 if there
 //   were warnings, 2 if any other problem, such as if a bad
@@ -276,9 +276,9 @@ std::error_code ModuleMapChecker::doChec
 // The following functions are called by doChecks.
 
 // Load module map.
-// Returns true if module.map file loaded successfully.
+// Returns true if module.modulemap file loaded successfully.
 bool ModuleMapChecker::loadModuleMap() {
-  // Get file entry for module.map file.
+  // Get file entry for module.modulemap file.
   const FileEntry *ModuleMapEntry =
       SourceMgr->getFileManager().getFile(ModuleMapPath);
 
@@ -305,7 +305,7 @@ bool ModuleMapChecker::loadModuleMap() {
     assert(Dir && "parent must exist");
   }
 
-  // Parse module.map file into module map.
+  // Parse module.modulemap file into module map.
   if (ModMap->parseModuleMapFile(ModuleMapEntry, false, Dir))
     return false;
 
@@ -429,18 +429,18 @@ void ModuleMapChecker::collectUmbrellaHe
 
 // Collect file system header files.
 // This function scans the file system for header files,
-// starting at the directory of the module.map file,
+// starting at the directory of the module.modulemap file,
 // optionally filtering out all but the files covered by
 // the include path options.
 // Returns true if no errors.
 bool ModuleMapChecker::collectFileSystemHeaders() {
 
-  // Get directory containing the module.map file.
+  // Get directory containing the module.modulemap file.
   // Might be relative to current directory, absolute, or empty.
   ModuleMapDirectory = getDirectoryFromPath(ModuleMapPath);
 
   // If no include paths specified, we do the whole tree starting
-  // at the module.map directory.
+  // at the module.modulemap directory.
   if (IncludePaths.size() == 0) {
     if (!collectFileSystemHeaders(StringRef("")))
       return false;
@@ -464,7 +464,7 @@ bool ModuleMapChecker::collectFileSystem
 // Collect file system header files from the given path.
 // This function scans the file system for header files,
 // starting at the given directory, which is assumed to be
-// relative to the directory of the module.map file.
+// relative to the directory of the module.modulemap file.
 // \returns True if no errors.
 bool ModuleMapChecker::collectFileSystemHeaders(StringRef IncludePath) {
 

Modified: clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.h
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.h?rev=228692&r1=228691&r2=228692&view=diff
==============================================================================
--- clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.h (original)
+++ clang-tools-extra/trunk/module-map-checker/ModuleMapChecker.h Tue Feb 10 08:29:16 2015
@@ -44,11 +44,11 @@ public:
 class ModuleMapChecker {
   // Checker arguments.
 
-  /// The module.map file path. Can be relative or absolute.
+  /// The module.modulemap file path. Can be relative or absolute.
   llvm::StringRef ModuleMapPath;
   /// The include paths to check for files.
   /// (Note that other directories above these paths are ignored.
-  /// To expect all files to be accounted for from the module.map
+  /// To expect all files to be accounted for from the module.modulemap
   /// file directory on down, leave this empty.)
   std::vector<std::string> IncludePaths;
   /// Flag to dump the module map information during check.
@@ -102,11 +102,11 @@ public:
   /// Constructor.
   /// You can use the static createModuleMapChecker to create an instance
   /// of this object.
-  /// \param ModuleMapPath The module.map file path.
+  /// \param ModuleMapPath The module.modulemap file path.
   ///   Can be relative or absolute.
   /// \param IncludePaths The include paths to check for files.
   ///   (Note that other directories above these paths are ignored.
-  ///   To expect all files to be accounted for from the module.map
+  ///   To expect all files to be accounted for from the module.modulemap
   ///   file directory on down, leave this empty.)
   /// \param DumpModuleMap Flag to dump the module map information
   ///   during check.
@@ -115,11 +115,11 @@ public:
                    llvm::ArrayRef<std::string> CommandLine);
 
   /// Create instance of ModuleMapChecker.
-  /// \param ModuleMapPath The module.map file path.
+  /// \param ModuleMapPath The module.modulemap file path.
   ///   Can be relative or absolute.
   /// \param IncludePaths The include paths to check for files.
   ///   (Note that other directories above these paths are ignored.
-  ///   To expect all files to be accounted for from the module.map
+  ///   To expect all files to be accounted for from the module.modulemap
   ///   file directory on down, leave this empty.)
   /// \param DumpModuleMap Flag to dump the module map information
   ///   during check.
@@ -129,10 +129,10 @@ public:
       bool DumpModuleMap, llvm::ArrayRef<std::string> CommandLine);
 
   /// Do checks.
-  /// Starting from the directory of the module.map file,
+  /// Starting from the directory of the module.modulemap file,
   /// Find all header files, optionally looking only at files
   /// covered by the include path options, and compare against
-  /// the headers referenced by the module.map file.
+  /// the headers referenced by the module.modulemap file.
   /// Display warnings for unaccounted-for header files.
   /// \returns 0 if there were no errors or warnings, 1 if there
   ///   were warnings, 2 if any other problem, such as a bad
@@ -142,7 +142,7 @@ public:
   // The following functions are called by doChecks.
 
   /// Load module map.
-  /// \returns True if module.map file loaded successfully.
+  /// \returns True if module.modulemap file loaded successfully.
   bool loadModuleMap();
 
   /// Collect module headers.
@@ -174,7 +174,7 @@ public:
 
   /// Collect file system header files.
   /// This function scans the file system for header files,
-  /// starting at the directory of the module.map file,
+  /// starting at the directory of the module.modulemap file,
   /// optionally filtering out all but the files covered by
   /// the include path options.
   /// \returns True if no errors.
@@ -183,7 +183,7 @@ public:
   /// Collect file system header files from the given path.
   /// This function scans the file system for header files,
   /// starting at the given directory, which is assumed to be
-  /// relative to the directory of the module.map file.
+  /// relative to the directory of the module.modulemap file.
   /// \returns True if no errors.
   bool collectFileSystemHeaders(llvm::StringRef IncludePath);
 

Removed: clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.map
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.map?rev=228691&view=auto
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.map (original)
+++ clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.map (removed)
@@ -1,10 +0,0 @@
-// module.map
-
-module Level1A {
-  header "Includes1/Level1A.h"
-  export *
-}
-module Level2A {
-  header "Includes2/Level2A.h"
-  export *
-}

Added: clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.modulemap
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.modulemap?rev=228692&view=auto
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.modulemap (added)
+++ clang-tools-extra/trunk/test/module-map-checker/Inputs/includes-test/module.modulemap Tue Feb 10 08:29:16 2015
@@ -0,0 +1,10 @@
+// module.modulemap
+
+module Level1A {
+  header "Includes1/Level1A.h"
+  export *
+}
+module Level2A {
+  header "Includes2/Level2A.h"
+  export *
+}

Removed: clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.map
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.map?rev=228691&view=auto
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.map (original)
+++ clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.map (removed)
@@ -1,30 +0,0 @@
-// module.map
-
-module Level1A {
-  header "Level1A.h"
-  export *
-}
-module Level1B {
-  header "Level1B.h"
-  export *
-  module Level2B {
-    header "Level2B.h"
-    export *
-  }
-}
-module Level2A {
-  header "Level2A.h"
-  export *
-}
-module UmbrellaDirectoryModule {
-  umbrella "UmbrellaSub"
-}
-module UmbrellaHeaderModule {
-  umbrella header "UmbrellaFile.h"
-}
-/*
-module NoHeader {
-  header "NoHeader.h"
-  export *
-}
-*/

Added: clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.modulemap
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.modulemap?rev=228692&view=auto
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.modulemap (added)
+++ clang-tools-extra/trunk/test/module-map-checker/Inputs/main-test/module.modulemap Tue Feb 10 08:29:16 2015
@@ -0,0 +1,30 @@
+// module.modulemap
+
+module Level1A {
+  header "Level1A.h"
+  export *
+}
+module Level1B {
+  header "Level1B.h"
+  export *
+  module Level2B {
+    header "Level2B.h"
+    export *
+  }
+}
+module Level2A {
+  header "Level2A.h"
+  export *
+}
+module UmbrellaDirectoryModule {
+  umbrella "UmbrellaSub"
+}
+module UmbrellaHeaderModule {
+  umbrella header "UmbrellaFile.h"
+}
+/*
+module NoHeader {
+  header "NoHeader.h"
+  export *
+}
+*/

Modified: clang-tools-extra/trunk/test/module-map-checker/includes.module-map-checker
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/includes.module-map-checker?rev=228692&r1=228691&r2=228692&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/includes.module-map-checker (original)
+++ clang-tools-extra/trunk/test/module-map-checker/includes.module-map-checker Tue Feb 10 08:29:16 2015
@@ -1 +1 @@
-# RUN: module-map-checker -I Includes1 -I Includes2 %S/Inputs/includes-test/module.map
+# RUN: module-map-checker -I Includes1 -I Includes2 %S/Inputs/includes-test/module.modulemap

Modified: clang-tools-extra/trunk/test/module-map-checker/main-test.module-map-checker
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/module-map-checker/main-test.module-map-checker?rev=228692&r1=228691&r2=228692&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/module-map-checker/main-test.module-map-checker (original)
+++ clang-tools-extra/trunk/test/module-map-checker/main-test.module-map-checker Tue Feb 10 08:29:16 2015
@@ -1,4 +1,4 @@
-# RUN: not module-map-checker %S/Inputs/main-test/module.map 2>&1 | FileCheck %s
+# RUN: not module-map-checker %S/Inputs/main-test/module.modulemap 2>&1 | FileCheck %s
 
-# CHECK: warning: {{.*}}{{[/\\]}}Inputs/main-test/module.map does not account for file: {{.*}}{{[/\\]}}Inputs/main-test/Level3A.h
-# CHECK-NEXT: warning: {{.*}}{{[/\\]}}Inputs/main-test/module.map does not account for file: {{.*}}{{[/\\]}}Inputs/main-test/Sub/Level3B.h
+# CHECK: warning: {{.*}}{{[/\\]}}Inputs/main-test/module.modulemap does not account for file: {{.*}}{{[/\\]}}Inputs/main-test/Level3A.h
+# CHECK-NEXT: warning: {{.*}}{{[/\\]}}Inputs/main-test/module.modulemap does not account for file: {{.*}}{{[/\\]}}Inputs/main-test/Sub/Level3B.h





More information about the cfe-commits mailing list