[clang] 303526e - [Docs] Add a link that refers to C++ standard modules in Clang modules doc

Jun Zhang via cfe-commits cfe-commits at lists.llvm.org
Sun Sep 18 03:32:42 PDT 2022


Author: Jun Zhang
Date: 2022-09-18T18:31:49+08:00
New Revision: 303526ef3aa211c1930be2885deae15eeeda3b18

URL: https://github.com/llvm/llvm-project/commit/303526ef3aa211c1930be2885deae15eeeda3b18
DIFF: https://github.com/llvm/llvm-project/commit/303526ef3aa211c1930be2885deae15eeeda3b18.diff

LOG: [Docs] Add a link that refers to C++ standard modules in Clang modules doc

Currently there're two pages that both talk about "Modules" in clang, but
they're different. The one that describes C++ standard modules explicitly
spells out the difference but the other one which targeting Clang modules
doesn't.

This patch adds a link that refers to the C++ standard modules
one in Clang modules doc, as you usually got the later page when
googling. I believe this will make newcomers less confused.

Signed-off-by: Jun Zhang <jun at junz.org>

Differential Revision: https://reviews.llvm.org/D134105

Added: 
    

Modified: 
    clang/docs/Modules.rst

Removed: 
    


################################################################################
diff  --git a/clang/docs/Modules.rst b/clang/docs/Modules.rst
index d85a60e881837..825d8722c4d53 100644
--- a/clang/docs/Modules.rst
+++ b/clang/docs/Modules.rst
@@ -102,6 +102,11 @@ Using Modules
 =============
 To enable modules, pass the command-line flag ``-fmodules``. This will make any modules-enabled software libraries available as modules as well as introducing any modules-specific syntax. Additional `command-line parameters`_ are described in a separate section later.
 
+Standard C++ Modules
+--------------------
+.. note::
+  Modules are adopted into C++20 Standard. And its semantic and command line interface are very 
diff erent from the Clang C++ modules. See `StandardCPlusPlusModules <StandardCPlusPlusModules.html>`_ for details.
+
 Objective-C Import declaration
 ------------------------------
 Objective-C provides syntax for importing a module via an *@import declaration*, which imports the named module:


        


More information about the cfe-commits mailing list