ruby-changes:51268
From: shyouhei <ko1@a...>
Date: Mon, 21 May 2018 09:42:05 +0900 (JST)
Subject: [ruby-changes:51268] shyouhei:r63474 (trunk): explicit cast to void* required for %p
shyouhei 2018-05-21 09:41:57 +0900 (Mon, 21 May 2018) New Revision: 63474 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=63474 Log: explicit cast to void* required for %p No automatic type promotion is expected for variadic arguments. You have to do it by hand. Modified files: trunk/parse.y Index: parse.y =================================================================== --- parse.y (revision 63473) +++ parse.y (revision 63474) @@ -4737,7 +4737,7 @@ vtable_alloc_gen(struct parser_params *p https://github.com/ruby/ruby/blob/trunk/parse.y#L4737 tbl->prev = prev; #ifndef RIPPER if (p->debug) { - rb_parser_printf(p, "vtable_alloc:%d: %p\n", line, tbl); + rb_parser_printf(p, "vtable_alloc:%d: %p\n", line, (void *)tbl); } #endif return tbl; @@ -4750,7 +4750,7 @@ vtable_free_gen(struct parser_params *p, https://github.com/ruby/ruby/blob/trunk/parse.y#L4750 { #ifndef RIPPER if (p->debug) { - rb_parser_printf(p, "vtable_free:%d: %s(%p)\n", line, name, tbl); + rb_parser_printf(p, "vtable_free:%d: %s(%p)\n", line, name, (void *)tbl); } #endif if (!DVARS_TERMINAL_P(tbl)) { @@ -4769,7 +4769,7 @@ vtable_add_gen(struct parser_params *p, https://github.com/ruby/ruby/blob/trunk/parse.y#L4769 #ifndef RIPPER if (p->debug) { rb_parser_printf(p, "vtable_add:%d: %s(%p), %s\n", - line, name, tbl, rb_id2name(id)); + line, name, (void *)tbl, rb_id2name(id)); } #endif if (DVARS_TERMINAL_P(tbl)) { @@ -4791,7 +4791,7 @@ vtable_pop_gen(struct parser_params *p, https://github.com/ruby/ruby/blob/trunk/parse.y#L4791 { if (p->debug) { rb_parser_printf(p, "vtable_pop:%d: %s(%p), %d\n", - line, name, tbl, n); + line, name, (void *)tbl, n); } if (tbl->pos < n) { rb_parser_fatal(p, "vtable_pop: unreachable (%d < %d)", tbl->pos, n); -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/