Ruby: include/ruby/internal/attr/format.h Source File

Ruby 3.0.5p211 (2022-11-24 revision ba5cf0f7c52d4d35cc6a173c89eda98ceffa2dcf)

format.h
Go to the documentation of this file.
1#ifndef RBIMPL_ATTR_FORMAT_H /*-*-C++-*-vi:se ft=cpp:*/
2#define RBIMPL_ATTR_FORMAT_H
23#include "ruby/internal/has/attribute.h"
24
26#if RBIMPL_HAS_ATTRIBUTE(format)
27# define RBIMPL_ATTR_FORMAT(x, y, z) __attribute__((__format__(x, y, z)))
28#else
29# define RBIMPL_ATTR_FORMAT(x, y, z) /* void */
30#endif
31
32#if defined(__MINGW_PRINTF_FORMAT)
33# define RBIMPL_PRINTF_FORMAT __MINGW_PRINTF_FORMAT
34#else
35# define RBIMPL_PRINTF_FORMAT __printf__
36#endif
37
38#endif /* RBIMPL_ATTR_FORMAT_H */
attribute.h
Defines RBIMPL_HAS_ATTRIBUTE.