diff options
| author | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2026-05-10 19:54:36 +0900 |
|---|---|---|
| committer | Nobuyoshi Nakada <nobu@ruby-lang.org> | 2026-05-10 19:54:36 +0900 |
| commit | 78562d38fb9e8079d6e810dc16c3594dc4515932 (patch) | |
| tree | 809b5bbc3596690eb8769e58ce8a3a28846080b1 | |
| parent | 8351378bf3173d48fd8510badf1139809553185a (diff) | |
mingw: Include stdio.h for `__MINGW_PRINTF_FORMAT`
This macro is not pre-defined but defined in stdio.h.
| -rw-r--r-- | include/ruby/internal/attr/format.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/ruby/internal/attr/format.h b/include/ruby/internal/attr/format.h index b3488ee00a..7feff1c846 100644 --- a/include/ruby/internal/attr/format.h +++ b/include/ruby/internal/attr/format.h @@ -22,6 +22,10 @@ */ #include "ruby/internal/has/attribute.h" +#if defined(__MINGW32__) +#include <stdio.h> /* for __MINGW_PRINTF_FORMAT */ +#endif + /** Wraps (or simulates) `__attribute__((format))` */ #if RBIMPL_HAS_ATTRIBUTE(format) # define RBIMPL_ATTR_FORMAT(x, y, z) __attribute__((__format__(x, y, z))) |
