Reorganize defines related to `MRB_INLINE`; ref #4391

parent 0c5f26e0
...@@ -54,12 +54,12 @@ MRB_BEGIN_DECL ...@@ -54,12 +54,12 @@ MRB_BEGIN_DECL
#endif #endif
/** Declare a function as always inlined. */ /** Declare a function as always inlined. */
#if defined(_MSC_VER) #if defined _MSC_VER && _MSC_VER < 1900
# define MRB_INLINE static __inline # ifndef __cplusplus
#else # define inline __inline
# define MRB_INLINE static inline # endif
#endif #endif
#define MRB_INLINE static inline
/** Declare a public MRuby API function. */ /** Declare a public MRuby API function. */
#if defined(MRB_BUILD_AS_DLL) #if defined(MRB_BUILD_AS_DLL)
......
...@@ -73,9 +73,6 @@ MRB_API double mrb_float_read(const char*, char**); ...@@ -73,9 +73,6 @@ MRB_API double mrb_float_read(const char*, char**);
#endif #endif
#if defined _MSC_VER && _MSC_VER < 1900 #if defined _MSC_VER && _MSC_VER < 1900
# ifndef __cplusplus
# define inline __inline
# endif
# include <stdarg.h> # include <stdarg.h>
MRB_API int mrb_msvc_vsnprintf(char *s, size_t n, const char *format, va_list arg); MRB_API int mrb_msvc_vsnprintf(char *s, size_t n, const char *format, va_list arg);
MRB_API int mrb_msvc_snprintf(char *s, size_t n, const char *format, ...); MRB_API int mrb_msvc_snprintf(char *s, size_t n, const char *format, ...);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment