diff options
author | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-25 07:13:03 +0000 |
---|---|---|
committer | usa <usa@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-25 07:13:03 +0000 |
commit | 67075af60033d765ac468dee7645cbc4f15da5bd (patch) | |
tree | 426aa8b4b8312d54e61616dbb6fbfd8dd8738689 /ext/-test-/printf/printf.c | |
parent | 9a66f6f07e89f431476feff1798eefcb48b5a46d (diff) | |
download | ruby-67075af60033d765ac468dee7645cbc4f15da5bd.tar.gz |
* trunk/ext/-test-/printf/printf.c: change function names because of
conflict with msvcrt. fixed build error of mswin.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35789 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/-test-/printf/printf.c')
-rw-r--r-- | ext/-test-/printf/printf.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/ext/-test-/printf/printf.c b/ext/-test-/printf/printf.c index f338637e04..775eb33dc7 100644 --- a/ext/-test-/printf/printf.c +++ b/ext/-test-/printf/printf.c @@ -2,7 +2,7 @@ #include <ruby/encoding.h> static VALUE -printf_i(VALUE self, VALUE obj) +printf_test_i(VALUE self, VALUE obj) { char buf[256]; snprintf(buf, sizeof(buf), "<%"PRIsVALUE">", obj); @@ -10,13 +10,13 @@ printf_i(VALUE self, VALUE obj) } static VALUE -printf_s(VALUE self, VALUE obj) +printf_test_s(VALUE self, VALUE obj) { return rb_enc_sprintf(rb_usascii_encoding(), "<%"PRIsVALUE">", obj); } static VALUE -printf_v(VALUE self, VALUE obj) +printf_test_v(VALUE self, VALUE obj) { return rb_enc_sprintf(rb_usascii_encoding(), "{%+"PRIsVALUE"}", obj); } @@ -25,7 +25,7 @@ void Init_printf(void) { VALUE m = rb_define_module_under(rb_define_module("Bug"), "Printf"); - rb_define_singleton_method(m, "i", printf_i, 1); - rb_define_singleton_method(m, "s", printf_s, 1); - rb_define_singleton_method(m, "v", printf_v, 1); + rb_define_singleton_method(m, "i", printf_test_i, 1); + rb_define_singleton_method(m, "s", printf_test_s, 1); + rb_define_singleton_method(m, "v", printf_test_v, 1); } |