Commit 36e010cd authored by Yukihiro "Matz" Matsumoto's avatar Yukihiro "Matz" Matsumoto

Merge branch 'deprecated' of https://github.com/furunkel/mruby into furunkel-deprecated

parents fb5af4de e90f0d51
......@@ -192,10 +192,13 @@ typedef struct mrb_state {
# define mrb_noreturn _Noreturn
#elif defined __GNUC__ && !defined __STRICT_ANSI__
# define mrb_noreturn __attribute__((noreturn))
# define mrb_deprecated __attribute__((deprecated))
#elif defined _MSC_VER
# define mrb_noreturn __declspec(noreturn)
# define mrb_deprecated __declspec(deprecated)
#else
# define mrb_noreturn
# define mrb_deprecated
#endif
typedef mrb_value (*mrb_func_t)(mrb_state *mrb, mrb_value);
......@@ -250,16 +253,6 @@ MRB_API struct RClass * mrb_define_module_under(mrb_state *mrb, struct RClass *o
/* accept no arguments */
#define MRB_ARGS_NONE() ((mrb_aspec)0)
/* compatibility macros; will be removed */
#define ARGS_REQ(n) MRB_ARGS_REQ(n)
#define ARGS_OPT(n) MRB_ARGS_OPT(n)
#define ARGS_REST() MRB_ARGS_REST()
#define ARGS_POST(n) MRB_ARGS_POST()
#define ARGS_KEY(n1,n2) MRB_ARGS_KEY(n1,n2)
#define ARGS_BLOCK() MRB_ARGS_BLOCK()
#define ARGS_ANY() MRB_ARGS_ANY()
#define ARGS_NONE() MRB_ARGS_NONE()
MRB_API mrb_int mrb_get_args(mrb_state *mrb, const char *format, ...);
/* `strlen` for character string literals (use with caution or `strlen` instead)
......@@ -459,6 +452,8 @@ MRB_API void mrb_show_copyright(mrb_state *mrb);
MRB_API mrb_value mrb_format(mrb_state *mrb, const char *format, ...);
#include "mruby/deprecated.h"
#if defined(__cplusplus)
} /* extern "C" { */
#endif
......
/* Deprecated macros and functions */
#define ARGS_REQ(n) MRB_ARGS_REQ(n)
#define ARGS_OPT(n) MRB_ARGS_OPT(n)
#define ARGS_REST() MRB_ARGS_REST()
#define ARGS_POST(n) MRB_ARGS_POST()
#define ARGS_KEY(n1,n2) MRB_ARGS_KEY(n1,n2)
#define ARGS_BLOCK() MRB_ARGS_BLOCK()
#define ARGS_ANY() MRB_ARGS_ANY()
#define ARGS_NONE() MRB_ARGS_NONE()
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