ruby-changes:26275
From: naruse <ko1@a...>
Date: Wed, 12 Dec 2012 06:18:40 +0900 (JST)
Subject: [ruby-changes:26275] naruse:r38332 (trunk): Experimental: don't use $.*s of fprintf
naruse 2012-12-12 06:17:37 +0900 (Wed, 12 Dec 2012) New Revision: 38332 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=38332 Log: Experimental: don't use $.*s of fprintf Modified files: trunk/vm_dump.c Index: vm_dump.c =================================================================== --- vm_dump.c (revision 38331) +++ vm_dump.c (revision 38332) @@ -676,7 +676,7 @@ int i; VALUE name; long len; - const int max_name_length = 128; + const int max_name_length = 1024; # define LIMITED_NAME_LENGTH(s) \ (((len = RSTRING_LEN(s)) > max_name_length) ? max_name_length : (int)len) @@ -688,8 +688,8 @@ for (i=0; i<RARRAY_LEN(vm->loaded_features); i++) { name = RARRAY_PTR(vm->loaded_features)[i]; if (RB_TYPE_P(name, T_STRING)) { - fprintf(stderr, " %4d %.*s\n", i, - LIMITED_NAME_LENGTH(name), RSTRING_PTR(name)); + fprintf(stderr, " %4d %s\n", i, + RSTRING_PTR(name)); } else { fprintf(stderr, " %4d #<%s:%p>\n", i, -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/