[ruby-cvs:65163] normal:r57997 (trunk): deduplicate static rb_str_format format strings

normal at ruby-lang.org normal at ruby-lang.org
Fri Mar 17 09:55:55 JST 2017


normal	2017-03-17 09:55:55 +0900 (Fri, 17 Mar 2017)

  New Revision: 57997

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=57997

  Log:
    deduplicate static rb_str_format format strings
    
    Anybody who hits these code paths can hit them again in the
    future, so try deduplicating across multiple runs of these
    methods to reduce garbage.
    
    * string.c (str_upto_each): fstring on "%.*d"
    * strftime.c (rb_strftime_with_timespec): fstring on "%0*d"

  Modified files:
    trunk/strftime.c
    trunk/string.c


More information about the ruby-cvs mailing list