@@ -352,7 +352,7 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
352
352
// / passed as the template parameter.
353
353
template <TagsType V>
354
354
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
355
- constexpr inline decltype (auto ) as() const & noexcept {
355
+ constexpr inline decltype (auto ) as() const & noexcept sus_lifetimebound {
356
356
::sus::check (index_ == index<V>);
357
357
return __private::find_choice_storage<index<V>>(storage_).as ();
358
358
}
@@ -376,7 +376,7 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
376
376
// / passed as the template parameter.
377
377
template <TagsType V>
378
378
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
379
- constexpr inline decltype (auto ) as_mut() & noexcept {
379
+ constexpr inline decltype (auto ) as_mut() & noexcept sus_lifetimebound {
380
380
::sus::check (index_ == index<V>);
381
381
return __private::find_choice_storage_mut<index<V>>(storage_).as_mut ();
382
382
}
@@ -411,7 +411,8 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
411
411
// / active member.
412
412
template <TagsType V>
413
413
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
414
- constexpr inline Option<AccessTypeOfTagConst<V>> get () const & noexcept {
414
+ constexpr inline Option<AccessTypeOfTagConst<V>> get () const & noexcept
415
+ sus_lifetimebound {
415
416
if (index_ != index<V>) return ::sus::none ();
416
417
return ::sus::some (__private::find_choice_storage<index<V>>(storage_).as ());
417
418
}
@@ -431,7 +432,8 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
431
432
// / active member.
432
433
template <TagsType V>
433
434
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
434
- constexpr inline Option<AccessTypeOfTagMut<V>> get_mut () & noexcept {
435
+ constexpr inline Option<AccessTypeOfTagMut<V>> get_mut () & noexcept
436
+ sus_lifetimebound {
435
437
if (index_ != index<V>) return ::sus::none ();
436
438
return ::sus::some (
437
439
__private::find_choice_storage_mut<index<V>>(storage_).as_mut ());
@@ -467,7 +469,7 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
467
469
template <TagsType V>
468
470
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
469
471
constexpr inline decltype (auto ) get_unchecked(
470
- ::sus::marker::UnsafeFnMarker) const & noexcept {
472
+ ::sus::marker::UnsafeFnMarker) const & noexcept sus_lifetimebound {
471
473
return __private::find_choice_storage<index<V>>(storage_).as ();
472
474
}
473
475
// If the storage is a value type, it can't be accessed by reference in an
@@ -492,7 +494,7 @@ class Choice<__private::TypeList<Ts...>, Tags...> final {
492
494
template <TagsType V>
493
495
requires (__private::ValueIsNotVoid<StorageTypeOfTag<V>>)
494
496
constexpr inline decltype (auto ) get_unchecked_mut(
495
- ::sus::marker::UnsafeFnMarker) & noexcept {
497
+ ::sus::marker::UnsafeFnMarker) & noexcept sus_lifetimebound {
496
498
return __private::find_choice_storage_mut<index<V>>(storage_).as_mut ();
497
499
}
498
500
0 commit comments