<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/98583>98583</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [C++ Modules] Exporting Redeclaration within language linkage
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            clang:modules
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          ChuanqiXu9
      </td>
    </tr>
</table>

<pre>
    This is discussed in WG21's mailing list. Although this is not formally merged into the standard, I think it is fine to work on it already.

Reproducer:

```
export module mod;
extern "C++" void func();
export extern "C++" {
    void func();
}
```

Clang now will reject it due to [[module.intefcae] p6](https://eel.is/c++draft/module.interface#6). But we think the rejection may not be necessary. Since the intention of [[module.intefcae] p6](https://eel.is/c++draft/module.interface#6) is to avoid the name conflicting. But the entities in language linkage are always attached to global module. So we don't need to worry about the name conflicting here.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy0VE2vqzYQ_TVmM3oIhhDCgkU-mqqLbt6r1G4HewD3Gju1zU3z7ysDVW_b22Uly1biOeM5c85AIejRMneivoj6ltESJ-e767SQ_U3_srRZ79Sr-2nSAXQApYNcQmAF2sLP32MpsAkwkzbajmB0iDmcTZzcMk4Qd5B1EQbnZzLmBTP7cYVHB3FiCJGsIq8EXuGHBLFvoGOCDdoyRAdP59_A2fQvGc-kXrkobqI4b_tXfninFsleVOePF-JY7Gv9yb8_nI8wO7UYToeoLn_eRPYWBOJV4GVdCO9OKxgWKwWeBLYfgtc0n2JEswcBwH8mEM3t0_q2_WrIjmDdE57aGPD8K8uYqKtlbcYq02UjkWsbeZDEor7B4yjqm8DTFOMjpE7gXeCd2eQ6CLzLrUrlaYgC7x8S-IEkC6yOAtscLkuEJ-86JH22CrSzMNNrlbJnsCw5BPKvHL5pK3mNTMnsGumG_7nOZI_ogNYep7ctzQzS2cFoGbUdNyLpJpUUNYdk2NTbhUYGo-1bOskzkHnSKwDFSHJilfKOxvVkdqvk8M2llihnBTYRLG9BT-f9C6h3-0P_LAEm9pxnqqtUW7WUcVc2WDQ1NlWZTV3THKuCirYcGolcHfq2ZsXHiplarGqV6Q4LPBRNiQXWWJZ5Sdzz4djWEk8tVVIcCk6TlxvzPufOj5kOYeGuPdWnKjPUswnrWCPKxFxU541REIhp1n2XkF_6ZQziUKThDX_lijqa9auw-xt-3LH1Db5bZyBx_MqKpSFPq-5PnXzzrzZnizfd3_UedZyWPpduFnhPb-7Hl4d3yW8C7yuZZImNz3uHfwQAAP__TAB-bQ">