Skip to content

Commit

Permalink
add constexpr noexcept (#5729)
Browse files Browse the repository at this point in the history
  • Loading branch information
tearfur committed Jul 5, 2023
1 parent 8543555 commit 2a9c30a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libtransmission/peer-mgr.cc
Original file line number Diff line number Diff line change
Expand Up @@ -166,17 +166,17 @@ struct peer_atom
return (flags & ADDED_F_SEED_FLAG) != 0;
}

[[nodiscard]] auto const& addr() const
[[nodiscard]] constexpr auto const& addr() const noexcept
{
return socket_address.first;
}

[[nodiscard]] auto& port()
[[nodiscard]] constexpr auto& port() noexcept
{
return socket_address.second;
}

[[nodiscard]] auto const& port() const
[[nodiscard]] constexpr auto const& port() const noexcept
{
return socket_address.second;
}
Expand Down

0 comments on commit 2a9c30a

Please sign in to comment.