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

Now U(*)[N] is convertible to cv U(*)[], can [util.smartptr.shared.general] be simplified? #4697

Open
cpplearner opened this issue Jun 13, 2021 · 0 comments

Comments

@cpplearner
Copy link
Contributor

[util.smartptr.shared.general]/6:

For the purposes of subclause [smartptr], a pointer type Y* is said to be compatible with a pointer type T* when either Y* is convertible to T* or Y is U[N] and T is cv U[].

IIUC, P0388R4 makes "pointer to array of N U" convertible to "pointer to array of unknown bound of (possibly cv-qualified) U". Hence, the definition is now equivalent to "Y* is compatible with T* when Y* is convertible to T*".

Does it make sense to strike this definition of "compatible with" and replace its use with "convertible to"?

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

No branches or pull requests

1 participant