C++ Logo

sg15

Advanced search

Re: Proposal for module metadata format to be used by the std library and others

From: Mark de Wever <koraq_at_[hidden]>
Date: Mon, 18 Mar 2024 14:11:10 +0100
Hi Daniel,

Ben Boeckel pointed out an inconsistency in libc++. I used
is-std-library and is-standard-library. I just noticed this was copied
from the example in the specification. For libc++ I now use
is-std-library.

On Tue, Dec 12, 2023 at 04:56:32PM -0500, Daniel Ruoso via SG15 wrote:
> * is-std-library (optional, default to false): Indicates that the module
> is allowed to use names that are reserved to the standard library.

...

> # Example
>
> Here's how I would expect that would look like for a standard library
> (assuming the modules file for now), such as libc++:
>
> {
> "version": 1,
> "revision": 1,
> "modules": [
> {
> "logical-name": "std",
> "source-path": "modules/std.cppm",
> "is-standard-library": true
> },
> {
> "logical-name": "std.compat",
> "source-path": "modules/std.compat.cppm"
> "is-std-library": true
> },
> {
> "logical-name": "std:someinterfacepartition",
> "source-path": "modules/std-someinterfacepartition.cppm"
> "is-std-library": true
> }
> ]
> }
>
> Note that this specifically doesn't use any of the local arguments, because
> I don't really think that's going to be needed for the standard library
> case. The only special case is the is-standard-library key, to allow the
> build system to know this is not an accidental collision with the reserved
> names. We may decide not to settle the local-arguments part of the proposal
> now for that reason.

Cheers,
Mark

Received on 2024-03-18 13:11:14