Skip to content

Commit 9a60702

Browse files
committed
Remove braces
1 parent a884b2a commit 9a60702

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

include/beman/optional26/optional.hpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -520,9 +520,8 @@ inline constexpr optional<T>& optional<T>::operator=(const optional<T>& rhs)
520520
reset();
521521
else if (has_value())
522522
value_ = rhs.value_;
523-
else {
523+
else
524524
construct(rhs.value_);
525-
}
526525
return *this;
527526
}
528527

@@ -536,9 +535,8 @@ optional<T>::operator=(optional<T>&& rhs) noexcept(std::is_nothrow_move_construc
536535
reset();
537536
else if (has_value())
538537
value_ = std::move(rhs.value_);
539-
else {
538+
else
540539
construct(std::move(rhs.value_));
541-
}
542540
return *this;
543541
}
544542

0 commit comments

Comments
 (0)