diff --git a/src/base/system.h b/src/base/system.h index 7ec1b2ee9..e4482f71f 100644 --- a/src/base/system.h +++ b/src/base/system.h @@ -1227,6 +1227,23 @@ void str_append(char (&dst)[N], const char *src) */ int str_copy(char *dst, const char *src, int dst_size); +/** + * Copies a string to a fixed-size array of chars. + * + * @ingroup Strings + * + * @param dst Array that shall receive the string. + * @param src String to be copied. + * + * @remark The strings are treated as zero-terminated strings. + * @remark Guarantees that dst string will contain zero-termination. + */ +template +void str_copy(char (&dst)[N], const char *src) +{ + str_copy(dst, src, N); +} + /** * Truncates a utf8 encoded string to a given length. * @@ -2797,23 +2814,6 @@ bool shell_unregister_application(const char *executable, bool *updated); void shell_update(); #endif -/** - * Copies a string to a fixed-size array of chars. - * - * @ingroup Strings - * - * @param dst Array that shall receive the string. - * @param src String to be copied. - * - * @remark The strings are treated as zero-terminated strings. - * @remark Guarantees that dst string will contain zero-termination. - */ -template -void str_copy(char (&dst)[N], const char *src) -{ - str_copy(dst, src, N); -} - template<> struct std::hash {