style: use the new paragraph comment style everywhere (#4634)

This commit is contained in:
Charles Kerr
2023-01-22 13:21:30 -06:00
committed by GitHub
parent 0f4077a445
commit 7367d465b5
30 changed files with 173 additions and 476 deletions

View File

@@ -56,9 +56,7 @@ struct tr_error;
#define tr_ngettext(singular, plural, count) ((count) == 1 ? (singular) : (plural))
#endif
/****
*****
****/
// ---
[[nodiscard]] std::string_view tr_get_mime_type_for_filename(std::string_view filename);
@@ -122,9 +120,7 @@ int tr_main_win32(int argc, char** argv, int (*real_main)(int, char**));
#endif
/***
****
***/
// ---
[[nodiscard]] constexpr bool tr_str_is_empty(char const* value)
{
@@ -154,9 +150,7 @@ template<typename T>
return out;
}
/***
**** std::string_view utils
***/
// --- std::string_view utils
template<typename T>
[[nodiscard]] constexpr bool tr_strvContains(std::string_view sv, T key) noexcept // c++23
@@ -221,9 +215,7 @@ constexpr bool tr_strvSep(std::string_view* sv, std::string_view* token, char de
*/
size_t tr_strvToBuf(std::string_view src, char* buf, size_t buflen);
/***
****
***/
// ---
/** @brief return TR_RATIO_NA, TR_RATIO_INF, or a number in [0..1]
@return TR_RATIO_NA, TR_RATIO_INF, or a number in [0..1] */
@@ -269,9 +261,7 @@ size_t tr_strvToBuf(std::string_view src, char* buf, size_t buflen);
*/
bool tr_moveFile(std::string_view oldpath, std::string_view newpath, struct tr_error** error = nullptr);
/***
****
***/
// ---
namespace libtransmission::detail::tr_time
{
@@ -305,9 +295,7 @@ constexpr void tr_timeUpdate(time_t now) noexcept
/** @brief Portability wrapper for htonll() that uses the system implementation if available */
[[nodiscard]] uint64_t tr_ntohll(uint64_t);
/***
****
***/
// ---
/* example: tr_formatter_size_init(1024, _("KiB"), _("MiB"), _("GiB"), _("TiB")); */
@@ -358,9 +346,7 @@ void tr_formatter_get_units(void* dict);
return size_t(B / (tr_mem_K * tr_mem_K));
}
/***
****
***/
// ---
/** @brief Check if environment variable exists. */
[[nodiscard]] bool tr_env_key_exists(char const* key);
@@ -371,8 +357,6 @@ void tr_formatter_get_units(void* dict);
/** @brief Get environment variable value as string. */
[[nodiscard]] std::string tr_env_get_string(std::string_view key, std::string_view default_value = {});
/***
****
***/
// ---
void tr_net_init();