Skip to content

Commit 84fc2c3

Browse files
committed
[libc++] Make the naming of private member variables consistent and enforce it through readability-identifier-naming
Reviewed By: ldionne, #libc Spies: aheejin, sstefan1, libcxx-commits Differential Revision: https://reviews.llvm.org/D129386
1 parent 3c355e2 commit 84fc2c3

37 files changed

+703
-696
lines changed

libcxx/.clang-tidy

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,12 @@ CheckOptions:
3939
value: lower_case
4040
- key: readability-identifier-naming.ParameterPrefix
4141
value: __
42+
- key: readability-identifier-naming.PrivateMemberCase
43+
value: lower_case
44+
- key: readability-identifier-naming.PrivateMemberPrefix
45+
value: __
46+
- key: readability-identifier-naming.PrivateMemberSuffix
47+
value: _
4248

4349
# TODO: investigate these checks
4450
# bugprone-branch-clone,

libcxx/include/__algorithm/shuffle.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,27 +31,27 @@ _LIBCPP_BEGIN_NAMESPACE_STD
3131
class _LIBCPP_TYPE_VIS __libcpp_debug_randomizer {
3232
public:
3333
__libcpp_debug_randomizer() {
34-
__state = __seed();
35-
__inc = __state + 0xda3e39cb94b95bdbULL;
36-
__inc = (__inc << 1) | 1;
34+
__state_ = __seed();
35+
__inc_ = __state_ + 0xda3e39cb94b95bdbULL;
36+
__inc_ = (__inc_ << 1) | 1;
3737
}
3838
typedef uint_fast32_t result_type;
3939

4040
static const result_type _Min = 0;
4141
static const result_type _Max = 0xFFFFFFFF;
4242

4343
_LIBCPP_HIDE_FROM_ABI result_type operator()() {
44-
uint_fast64_t __oldstate = __state;
45-
__state = __oldstate * 6364136223846793005ULL + __inc;
44+
uint_fast64_t __oldstate = __state_;
45+
__state_ = __oldstate * 6364136223846793005ULL + __inc_;
4646
return __oldstate >> 32;
4747
}
4848

4949
static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR result_type min() { return _Min; }
5050
static _LIBCPP_HIDE_FROM_ABI _LIBCPP_CONSTEXPR result_type max() { return _Max; }
5151

5252
private:
53-
uint_fast64_t __state;
54-
uint_fast64_t __inc;
53+
uint_fast64_t __state_;
54+
uint_fast64_t __inc_;
5555
_LIBCPP_HIDE_FROM_ABI static uint_fast64_t __seed() {
5656
#ifdef _LIBCPP_DEBUG_RANDOMIZE_UNSPECIFIED_STABILITY_SEED
5757
return _LIBCPP_DEBUG_RANDOMIZE_UNSPECIFIED_STABILITY_SEED;

libcxx/include/__algorithm/uniform_random_bit_generator_adaptor.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ template <class _Gen>
3636
class _ClassicGenAdaptor {
3737
private:
3838
// The generator is not required to be copyable or movable, so it has to be stored as a reference.
39-
_Gen& __gen;
39+
_Gen& __gen_;
4040

4141
public:
4242
using result_type = invoke_result_t<_Gen&>;
@@ -47,10 +47,10 @@ class _ClassicGenAdaptor {
4747
static constexpr auto max() { return __uncvref_t<_Gen>::max(); }
4848

4949
_LIBCPP_HIDE_FROM_ABI
50-
constexpr explicit _ClassicGenAdaptor(_Gen& __g) : __gen(__g) {}
50+
constexpr explicit _ClassicGenAdaptor(_Gen& __g) : __gen_(__g) {}
5151

5252
_LIBCPP_HIDE_FROM_ABI
53-
constexpr auto operator()() const { return __gen(); }
53+
constexpr auto operator()() const { return __gen_(); }
5454
};
5555

5656
_LIBCPP_END_NAMESPACE_STD

libcxx/include/__chrono/day.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,18 @@ namespace chrono
2727

2828
class day {
2929
private:
30-
unsigned char __d;
30+
unsigned char __d_;
3131
public:
3232
_LIBCPP_HIDE_FROM_ABI day() = default;
33-
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr day(unsigned __val) noexcept : __d(static_cast<unsigned char>(__val)) {}
34-
_LIBCPP_HIDE_FROM_ABI inline constexpr day& operator++() noexcept { ++__d; return *this; }
33+
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr day(unsigned __val) noexcept : __d_(static_cast<unsigned char>(__val)) {}
34+
_LIBCPP_HIDE_FROM_ABI inline constexpr day& operator++() noexcept { ++__d_; return *this; }
3535
_LIBCPP_HIDE_FROM_ABI inline constexpr day operator++(int) noexcept { day __tmp = *this; ++(*this); return __tmp; }
36-
_LIBCPP_HIDE_FROM_ABI inline constexpr day& operator--() noexcept { --__d; return *this; }
36+
_LIBCPP_HIDE_FROM_ABI inline constexpr day& operator--() noexcept { --__d_; return *this; }
3737
_LIBCPP_HIDE_FROM_ABI inline constexpr day operator--(int) noexcept { day __tmp = *this; --(*this); return __tmp; }
3838
_LIBCPP_HIDE_FROM_ABI constexpr day& operator+=(const days& __dd) noexcept;
3939
_LIBCPP_HIDE_FROM_ABI constexpr day& operator-=(const days& __dd) noexcept;
40-
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr operator unsigned() const noexcept { return __d; }
41-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __d >= 1 && __d <= 31; }
40+
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr operator unsigned() const noexcept { return __d_; }
41+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __d_ >= 1 && __d_ <= 31; }
4242
};
4343

4444

libcxx/include/__chrono/hh_mm_ss.h

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -57,33 +57,33 @@ class hh_mm_ss
5757
_LIBCPP_HIDE_FROM_ABI constexpr hh_mm_ss() noexcept : hh_mm_ss{_Duration::zero()} {}
5858

5959
_LIBCPP_HIDE_FROM_ABI constexpr explicit hh_mm_ss(_Duration __d) noexcept :
60-
__is_neg(__d < _Duration(0)),
61-
__h(duration_cast<chrono::hours> (abs(__d))),
62-
__m(duration_cast<chrono::minutes>(abs(__d) - hours())),
63-
__s(duration_cast<chrono::seconds>(abs(__d) - hours() - minutes())),
64-
__f(duration_cast<precision> (abs(__d) - hours() - minutes() - seconds()))
60+
__is_neg_(__d < _Duration(0)),
61+
__h_(duration_cast<chrono::hours> (abs(__d))),
62+
__m_(duration_cast<chrono::minutes>(abs(__d) - hours())),
63+
__s_(duration_cast<chrono::seconds>(abs(__d) - hours() - minutes())),
64+
__f_(duration_cast<precision> (abs(__d) - hours() - minutes() - seconds()))
6565
{}
6666

67-
_LIBCPP_HIDE_FROM_ABI constexpr bool is_negative() const noexcept { return __is_neg; }
68-
_LIBCPP_HIDE_FROM_ABI constexpr chrono::hours hours() const noexcept { return __h; }
69-
_LIBCPP_HIDE_FROM_ABI constexpr chrono::minutes minutes() const noexcept { return __m; }
70-
_LIBCPP_HIDE_FROM_ABI constexpr chrono::seconds seconds() const noexcept { return __s; }
71-
_LIBCPP_HIDE_FROM_ABI constexpr precision subseconds() const noexcept { return __f; }
67+
_LIBCPP_HIDE_FROM_ABI constexpr bool is_negative() const noexcept { return __is_neg_; }
68+
_LIBCPP_HIDE_FROM_ABI constexpr chrono::hours hours() const noexcept { return __h_; }
69+
_LIBCPP_HIDE_FROM_ABI constexpr chrono::minutes minutes() const noexcept { return __m_; }
70+
_LIBCPP_HIDE_FROM_ABI constexpr chrono::seconds seconds() const noexcept { return __s_; }
71+
_LIBCPP_HIDE_FROM_ABI constexpr precision subseconds() const noexcept { return __f_; }
7272

7373
_LIBCPP_HIDE_FROM_ABI constexpr precision to_duration() const noexcept
7474
{
75-
auto __dur = __h + __m + __s + __f;
76-
return __is_neg ? -__dur : __dur;
75+
auto __dur = __h_ + __m_ + __s_ + __f_;
76+
return __is_neg_ ? -__dur : __dur;
7777
}
7878

7979
_LIBCPP_HIDE_FROM_ABI constexpr explicit operator precision() const noexcept { return to_duration(); }
8080

8181
private:
82-
bool __is_neg;
83-
chrono::hours __h;
84-
chrono::minutes __m;
85-
chrono::seconds __s;
86-
precision __f;
82+
bool __is_neg_;
83+
chrono::hours __h_;
84+
chrono::minutes __m_;
85+
chrono::seconds __s_;
86+
precision __f_;
8787
};
8888

8989
_LIBCPP_HIDE_FROM_ABI constexpr bool is_am(const hours& __h) noexcept { return __h >= hours( 0) && __h < hours(12); }

libcxx/include/__chrono/month.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,18 @@ namespace chrono
2727

2828
class month {
2929
private:
30-
unsigned char __m;
30+
unsigned char __m_;
3131
public:
3232
_LIBCPP_HIDE_FROM_ABI month() = default;
33-
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr month(unsigned __val) noexcept : __m(static_cast<unsigned char>(__val)) {}
34-
_LIBCPP_HIDE_FROM_ABI inline constexpr month& operator++() noexcept { ++__m; return *this; }
33+
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr month(unsigned __val) noexcept : __m_(static_cast<unsigned char>(__val)) {}
34+
_LIBCPP_HIDE_FROM_ABI inline constexpr month& operator++() noexcept { ++__m_; return *this; }
3535
_LIBCPP_HIDE_FROM_ABI inline constexpr month operator++(int) noexcept { month __tmp = *this; ++(*this); return __tmp; }
36-
_LIBCPP_HIDE_FROM_ABI inline constexpr month& operator--() noexcept { --__m; return *this; }
36+
_LIBCPP_HIDE_FROM_ABI inline constexpr month& operator--() noexcept { --__m_; return *this; }
3737
_LIBCPP_HIDE_FROM_ABI inline constexpr month operator--(int) noexcept { month __tmp = *this; --(*this); return __tmp; }
3838
_LIBCPP_HIDE_FROM_ABI constexpr month& operator+=(const months& __m1) noexcept;
3939
_LIBCPP_HIDE_FROM_ABI constexpr month& operator-=(const months& __m1) noexcept;
40-
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr operator unsigned() const noexcept { return __m; }
41-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m >= 1 && __m <= 12; }
40+
_LIBCPP_HIDE_FROM_ABI explicit inline constexpr operator unsigned() const noexcept { return __m_; }
41+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m_ >= 1 && __m_ <= 12; }
4242
};
4343

4444

libcxx/include/__chrono/month_weekday.h

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,14 @@ namespace chrono
2727

2828
class month_weekday {
2929
private:
30-
chrono::month __m;
31-
chrono::weekday_indexed __wdi;
30+
chrono::month __m_;
31+
chrono::weekday_indexed __wdi_;
3232
public:
3333
_LIBCPP_HIDE_FROM_ABI constexpr month_weekday(const chrono::month& __mval, const chrono::weekday_indexed& __wdival) noexcept
34-
: __m{__mval}, __wdi{__wdival} {}
35-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m; }
36-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday_indexed weekday_indexed() const noexcept { return __wdi; }
37-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m.ok() && __wdi.ok(); }
34+
: __m_{__mval}, __wdi_{__wdival} {}
35+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m_; }
36+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday_indexed weekday_indexed() const noexcept { return __wdi_; }
37+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m_.ok() && __wdi_.ok(); }
3838
};
3939

4040
_LIBCPP_HIDE_FROM_ABI inline constexpr
@@ -63,14 +63,14 @@ month_weekday operator/(const weekday_indexed& __lhs, int __rhs) noexcept
6363

6464

6565
class month_weekday_last {
66-
chrono::month __m;
67-
chrono::weekday_last __wdl;
66+
chrono::month __m_;
67+
chrono::weekday_last __wdl_;
6868
public:
6969
_LIBCPP_HIDE_FROM_ABI constexpr month_weekday_last(const chrono::month& __mval, const chrono::weekday_last& __wdlval) noexcept
70-
: __m{__mval}, __wdl{__wdlval} {}
71-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m; }
72-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday_last weekday_last() const noexcept { return __wdl; }
73-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m.ok() && __wdl.ok(); }
70+
: __m_{__mval}, __wdl_{__wdlval} {}
71+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m_; }
72+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday_last weekday_last() const noexcept { return __wdl_; }
73+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m_.ok() && __wdl_.ok(); }
7474
};
7575

7676
_LIBCPP_HIDE_FROM_ABI inline constexpr

libcxx/include/__chrono/monthday.h

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -29,26 +29,26 @@ namespace chrono
2929

3030
class month_day {
3131
private:
32-
chrono::month __m;
33-
chrono::day __d;
32+
chrono::month __m_;
33+
chrono::day __d_;
3434
public:
3535
_LIBCPP_HIDE_FROM_ABI month_day() = default;
3636
_LIBCPP_HIDE_FROM_ABI constexpr month_day(const chrono::month& __mval, const chrono::day& __dval) noexcept
37-
: __m{__mval}, __d{__dval} {}
38-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m; }
39-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::day day() const noexcept { return __d; }
37+
: __m_{__mval}, __d_{__dval} {}
38+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m_; }
39+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::day day() const noexcept { return __d_; }
4040
_LIBCPP_HIDE_FROM_ABI constexpr bool ok() const noexcept;
4141
};
4242

4343
_LIBCPP_HIDE_FROM_ABI inline constexpr
4444
bool month_day::ok() const noexcept
4545
{
46-
if (!__m.ok()) return false;
47-
const unsigned __dval = static_cast<unsigned>(__d);
46+
if (!__m_.ok()) return false;
47+
const unsigned __dval = static_cast<unsigned>(__d_);
4848
if (__dval < 1 || __dval > 31) return false;
4949
if (__dval <= 29) return true;
5050
// Now we've got either 30 or 31
51-
const unsigned __mval = static_cast<unsigned>(__m);
51+
const unsigned __mval = static_cast<unsigned>(__m_);
5252
if (__mval == 2) return false;
5353
if (__mval == 4 || __mval == 6 || __mval == 9 || __mval == 11)
5454
return __dval == 30;
@@ -87,12 +87,12 @@ month_day operator/(const day& __lhs, int __rhs) noexcept
8787

8888
class month_day_last {
8989
private:
90-
chrono::month __m;
90+
chrono::month __m_;
9191
public:
9292
_LIBCPP_HIDE_FROM_ABI explicit constexpr month_day_last(const chrono::month& __val) noexcept
93-
: __m{__val} {}
94-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m; }
95-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m.ok(); }
93+
: __m_{__val} {}
94+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::month month() const noexcept { return __m_; }
95+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __m_.ok(); }
9696
};
9797

9898
_LIBCPP_HIDE_FROM_ABI inline constexpr

libcxx/include/__chrono/weekday.h

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -32,25 +32,25 @@ class weekday_last;
3232

3333
class weekday {
3434
private:
35-
unsigned char __wd;
35+
unsigned char __wd_;
3636
_LIBCPP_HIDE_FROM_ABI static constexpr unsigned char __weekday_from_days(int __days) noexcept;
3737
public:
3838
_LIBCPP_HIDE_FROM_ABI weekday() = default;
39-
_LIBCPP_HIDE_FROM_ABI inline explicit constexpr weekday(unsigned __val) noexcept : __wd(static_cast<unsigned char>(__val == 7 ? 0 : __val)) {}
39+
_LIBCPP_HIDE_FROM_ABI inline explicit constexpr weekday(unsigned __val) noexcept : __wd_(static_cast<unsigned char>(__val == 7 ? 0 : __val)) {}
4040
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday(const sys_days& __sysd) noexcept
41-
: __wd(__weekday_from_days(__sysd.time_since_epoch().count())) {}
41+
: __wd_(__weekday_from_days(__sysd.time_since_epoch().count())) {}
4242
_LIBCPP_HIDE_FROM_ABI inline explicit constexpr weekday(const local_days& __locd) noexcept
43-
: __wd(__weekday_from_days(__locd.time_since_epoch().count())) {}
43+
: __wd_(__weekday_from_days(__locd.time_since_epoch().count())) {}
4444

45-
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday& operator++() noexcept { __wd = (__wd == 6 ? 0 : __wd + 1); return *this; }
45+
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday& operator++() noexcept { __wd_ = (__wd_ == 6 ? 0 : __wd_ + 1); return *this; }
4646
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday operator++(int) noexcept { weekday __tmp = *this; ++(*this); return __tmp; }
47-
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday& operator--() noexcept { __wd = (__wd == 0 ? 6 : __wd - 1); return *this; }
47+
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday& operator--() noexcept { __wd_ = (__wd_ == 0 ? 6 : __wd_ - 1); return *this; }
4848
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday operator--(int) noexcept { weekday __tmp = *this; --(*this); return __tmp; }
4949
_LIBCPP_HIDE_FROM_ABI constexpr weekday& operator+=(const days& __dd) noexcept;
5050
_LIBCPP_HIDE_FROM_ABI constexpr weekday& operator-=(const days& __dd) noexcept;
51-
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned c_encoding() const noexcept { return __wd; }
52-
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned iso_encoding() const noexcept { return __wd == 0u ? 7 : __wd; }
53-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __wd <= 6; }
51+
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned c_encoding() const noexcept { return __wd_; }
52+
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned iso_encoding() const noexcept { return __wd_ == 0u ? 7 : __wd_; }
53+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __wd_ <= 6; }
5454
_LIBCPP_HIDE_FROM_ABI constexpr weekday_indexed operator[](unsigned __index) const noexcept;
5555
_LIBCPP_HIDE_FROM_ABI constexpr weekday_last operator[](last_spec) const noexcept;
5656
};
@@ -123,15 +123,15 @@ weekday& weekday::operator-=(const days& __dd) noexcept
123123

124124
class weekday_indexed {
125125
private:
126-
chrono::weekday __wd;
127-
unsigned char __idx;
126+
chrono::weekday __wd_;
127+
unsigned char __idx_;
128128
public:
129129
_LIBCPP_HIDE_FROM_ABI weekday_indexed() = default;
130130
_LIBCPP_HIDE_FROM_ABI inline constexpr weekday_indexed(const chrono::weekday& __wdval, unsigned __idxval) noexcept
131-
: __wd{__wdval}, __idx(__idxval) {}
132-
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday weekday() const noexcept { return __wd; }
133-
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned index() const noexcept { return __idx; }
134-
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __wd.ok() && __idx >= 1 && __idx <= 5; }
131+
: __wd_{__wdval}, __idx_(__idxval) {}
132+
_LIBCPP_HIDE_FROM_ABI inline constexpr chrono::weekday weekday() const noexcept { return __wd_; }
133+
_LIBCPP_HIDE_FROM_ABI inline constexpr unsigned index() const noexcept { return __idx_; }
134+
_LIBCPP_HIDE_FROM_ABI inline constexpr bool ok() const noexcept { return __wd_.ok() && __idx_ >= 1 && __idx_ <= 5; }
135135
};
136136

137137
_LIBCPP_HIDE_FROM_ABI inline constexpr
@@ -145,12 +145,12 @@ bool operator!=(const weekday_indexed& __lhs, const weekday_indexed& __rhs) noex
145145

146146
class weekday_last {
147147
private:
148-
chrono::weekday __wd;
148+
chrono::weekday __wd_;
149149
public:
150150
_LIBCPP_HIDE_FROM_ABI explicit constexpr weekday_last(const chrono::weekday& __val) noexcept
151-
: __wd{__val} {}
152-
_LIBCPP_HIDE_FROM_ABI constexpr chrono::weekday weekday() const noexcept { return __wd; }
153-
_LIBCPP_HIDE_FROM_ABI constexpr bool ok() const noexcept { return __wd.ok(); }
151+
: __wd_{__val} {}
152+
_LIBCPP_HIDE_FROM_ABI constexpr chrono::weekday weekday() const noexcept { return __wd_; }
153+
_LIBCPP_HIDE_FROM_ABI constexpr bool ok() const noexcept { return __wd_.ok(); }
154154
};
155155

156156
_LIBCPP_HIDE_FROM_ABI inline constexpr

0 commit comments

Comments
 (0)