[libc++] LWG3001: add `remove_extent_t` to `weak_ptr::element_type`.
authorKonstantin Varlamov <varconst@apple.com>
Mon, 25 Oct 2021 15:15:38 +0000 (11:15 -0400)
committerLouis Dionne <ldionne.2@gmail.com>
Mon, 25 Oct 2021 15:15:54 +0000 (11:15 -0400)
commit065ac30026d506172994310bd5badd65120f7d74
tree06678224b564c5468492ab74e06aa853c1931820
parenta5435844f0e67c70963a1a743fef41b1a8eac4d3
[libc++] LWG3001: add `remove_extent_t` to `weak_ptr::element_type`.

Also fix a few places in the `shared_ptr` implementation where
`element_type` was passed to the `__is_compatible` helper. This could
result in `remove_extent` being applied twice to the pointer's template
type (first by the definition of `element_type` and then by the helper),
potentially leading to somewhat less readable error messages for some
incorrect code.

Differential Revision: https://reviews.llvm.org/D112092
libcxx/docs/Status/Cxx20Issues.csv
libcxx/include/__memory/shared_ptr.h
libcxx/include/memory
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/types.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/weak_ptr.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.weak/types.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.assign/shared_ptr_Y.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.assign/weak_ptr_Y.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/shared_ptr_Y.pass.cpp
libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.weak/util.smartptr.weak.const/weak_ptr_Y.pass.cpp