Skip to content
New issue

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

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

Already on GitHub? # to your account

[text.encoding.aliases] Add note about what isn't required #7237

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jwakely
Copy link
Member

@jwakely jwakely commented Aug 20, 2024

Make it explicit that copyable is intended, rather than semiregular, and that the return types of begin() and end() can differ.

Also remove a FIXME comment for something that doesn't need fixing. These requirements on a type are specified in our usual form, it would be wrong to use Remarks: or Requires: here.

Make it explicit that `copyable` is intended, rather than `semiregular`,
and that the return types of `begin()` and `end()` can differ.

Also remove a FIXME comment for something that doesn't need fixing.
These requirements on a type are specified in our usual form, it would
be wrong to use _Remarks_: or _Requires_: here.
@jwakely
Copy link
Member Author

jwakely commented Aug 20, 2024

This came up in a GCC bug report where it was suggested that the presentation of aliases_view as an apparently empty class suggests it should be default initializable. It was also questioned whether the implementation defined return types need to be the same type or not.

@cor3ntin confirmed the intent of the P1885R12 design, which is that it models copyable but not necessarily default_initializable, and models range but not necessarily common_range. Add a note to make it clear that the normative requirements are what's required, and no more.

Please say if you'd rather have an LWG issue for this. I'd be inclined to vote NAD on such an issue, but at least we'd have the issues list recording that the normative requirements are correct as written.

@cor3ntin
Copy link
Contributor

I'm happy with the change

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants