diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-04-17 01:35:54 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2017-04-17 01:35:54 +0000 |
commit | 158c742b51556ff416d2934fcb215ef77e7d0c7e (patch) | |
tree | bf99e9d777b5b6483e4f8f6b57db85aed897160c /parse.y | |
parent | 269421084e630ab2b5ca1af4becb3ebbfdcdce29 (diff) | |
download | ruby-158c742b51556ff416d2934fcb215ef77e7d0c7e.tar.gz |
parse.y: fix for empty `__VA_ARGS__`
* parse.y (WARN_CALL, WARNING_CALL): need `##` between a comman
and `__VA_ARGS__` in the case it is empty, not to end arguments
with a comma.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58378 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r-- | parse.y | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -832,14 +832,14 @@ static ID id_warn, id_warning, id_gets; # define WARN_ARGS(fmt,n) parser->value, id_warn, n, rb_usascii_str_new_lit(fmt) # define WARN_ARGS_L(l,fmt,n) WARN_ARGS(fmt,n) # ifdef HAVE_VA_ARGS_MACRO -# define WARN_CALL(args,...) rb_funcall(args,__VA_ARGS__) +# define WARN_CALL(args,...) rb_funcall(args,##__VA_ARGS__) # else # define WARN_CALL rb_funcall # endif # define WARNING_ARGS(fmt,n) parser->value, id_warning, n, rb_usascii_str_new_lit(fmt) # define WARNING_ARGS_L(l, fmt,n) WARNING_ARGS(fmt,n) # ifdef HAVE_VA_ARGS_MACRO -# define WARNING_CALL(args,...) rb_funcall(args,__VA_ARGS__) +# define WARNING_CALL(args,...) rb_funcall(args,##__VA_ARGS__) # else # define WARNING_CALL rb_funcall # endif |