Skip to content

Commit cb5c09f

Browse files
committed
ARMC5 std::reference_wrapper - drop dead code
1 parent 71a5f85 commit cb5c09f

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

platform/cxxsupport/mstd_functional

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -89,23 +89,14 @@ namespace std {
8989
// [refwrap]
9090
template <typename T>
9191
class reference_wrapper {
92-
T &FUN(T &x) noexcept { return x; }
93-
void FUN(T &&x) = delete;
9492
T *ptr;
9593
public:
9694
using type = T;
9795
// [refwrap.const]
98-
#if 0
99-
// decltype doesn't seem to work well enough for this revised version
100-
template <typename U,
101-
typename = enable_if_t<!is_same<reference_wrapper, decay_t<U>>::value &&
102-
!is_void<decltype(FUN(declval<U>()))>::value>>
103-
reference_wrapper(U&& x) //noexcept(noexcept(FUN(declval<U>())))
104-
: ptr(addressof(FUN(forward<U>(x)))) { }
105-
#else
96+
// LWG 2993 version of constructor does not seem to work in ARM C 5, so stick with
97+
// this original version.
10698
reference_wrapper(T &x) noexcept : ptr(addressof(x)) { }
10799
reference_wrapper(T &&x) = delete;
108-
#endif
109100

110101
reference_wrapper(const reference_wrapper &) noexcept = default;
111102
// [refwrap.assign]

0 commit comments

Comments
 (0)