mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-04-20 19:44:57 +00:00
Give StringFromFormat a printf format attribute.
It gives StringFromFormat printf style arguments that should be type-checked against a format string.
This commit is contained in:
parent
2356e2950f
commit
09cc7e2ddf
1 changed files with 8 additions and 1 deletions
|
@ -14,7 +14,14 @@
|
|||
|
||||
#include "Common.h"
|
||||
|
||||
std::string StringFromFormat(const char* format, ...);
|
||||
std::string StringFromFormat(const char* format, ...)
|
||||
#if !defined _WIN32
|
||||
// On compilers that support function attributes, this gives StringFromFormat
|
||||
// the same errors and warnings that printf would give.
|
||||
__attribute__ ((__format__(printf, 1, 2)))
|
||||
#endif
|
||||
;
|
||||
|
||||
// Cheap!
|
||||
bool CharArrayFromFormatV(char* out, int outsize, const char* format, va_list args);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue