Mercurial > molko
diff libcore/core/error.h @ 168:aab824406d3d
misc: all printf-like function are name foof and vfoof
author | David Demelier <markand@malikania.fr> |
---|---|
date | Tue, 20 Oct 2020 15:09:39 +0200 |
parents | 789b23e01f52 |
children | eb0a7ab71023 |
line wrap: on
line diff
--- a/libcore/core/error.h Tue Oct 20 14:58:51 2020 +0200 +++ b/libcore/core/error.h Tue Oct 20 15:09:39 2020 +0200 @@ -39,6 +39,27 @@ error(void); /** + * Set the game error with a printf-like format. + * + * \pre fmt != NULL + * \param fmt the format string + * \return Always false. + */ +bool +errorf(const char *fmt, ...) PLAT_PRINTF(1, 2); + +/** + * Similar to \ref errorf. + * + * \pre fmt != NULL + * \param fmt the format stinrg + * \param ap the variadic arguments pointer + * \return Always false. + */ +bool +verrorf(const char *fmt, va_list ap) PLAT_PRINTF(1, 0); + +/** * Convenient helper that sets last error from global C errno and then return * false. * @@ -47,25 +68,4 @@ bool error_errno(void); -/** - * Set the game error with a printf-like format. - * - * \pre fmt != NULL - * \param fmt the format string - * \return Always false. - */ -bool -error_printf(const char *fmt, ...) PLAT_PRINTF(1, 2); - -/** - * Similar to \ref error_printf. - * - * \pre fmt != NULL - * \param fmt the format stinrg - * \param ap the variadic arguments pointer - * \return Always false. - */ -bool -error_vprintf(const char *fmt, va_list ap) PLAT_PRINTF(1, 0); - #endif /* !MOLKO_ERROR_H */