Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent description of C++ extensions to header <cstddef> LWG3484 #4144

Closed
AlisdairM opened this issue Sep 6, 2020 · 3 comments · Fixed by #4145
Closed

Inconsistent description of C++ extensions to header <cstddef> LWG3484 #4144

AlisdairM opened this issue Sep 6, 2020 · 3 comments · Fixed by #4145

Comments

@AlisdairM
Copy link
Contributor

In addition to importing the contents of <stddef.h> into namespace std, the header also adds the typedef nullptr_t, and type byte, and operations on type byte. This additions are partially described in two different locations:
[cstddef.syn]p1 notes the addition of byte and its operations, but makes no mention of nullptr_t.
[diff.mods.to.declarations]p3 (in the C compatibility annex) notes the addition of nullptr_t, but says nothing about byte and its operations.

For consistency, we should either consolidate this descriptive material to either one place, or duplicate it completely in both. Opening and issue, rather than filing an initial PR, as not sure which direction would be preferred.

@tkoeppe
Copy link
Contributor

tkoeppe commented Sep 6, 2020

As far as I can tell, [cstddef.syn] does contain nullptr_t,

using nullptr_t = decltype(nullptr);
.

I agree that we should add mention of nullptr_t to [depr.c.header.others].

@tkoeppe
Copy link
Contributor

tkoeppe commented Sep 6, 2020

As @jwakely noted in my attempted PR, modifying [depr.c.header.others] is a normative change that I'd like to discuss in an issue. I will open one if you don't mind.

PR #4145 contains a proposed change to [diff.mods.to.declarations], could you please take a look?

@jensmaurer
Copy link
Member

See LWG3484

@jensmaurer jensmaurer changed the title Inconsistent description of C++ extensions to header <cstddef> Inconsistent description of C++ extensions to header <cstddef> LWG3484 May 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants