Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

There was a problem

You must be a member of this account.

This project is archived and is in readonly mode.

Ruby 1.9 compat: add String#bytesize

#1968

Added String#bytesize to ActiveSupport, since we (multibytish language users) came to use that new method in some cases.

Reported by Akira Matsuda · February 14th, 2009 @ 07:10 AM

State: invalid
Milestone: 2.x
Assigned to: nobody
Importance: none

Activity

  1. Manfred Stienstra
    Manfred Stienstra

    Looks like a good idea. Can you add a unit test to the patch?

    February 14th, 2009 @ 07:49 AM

  2. Akira Matsuda
    Akira Matsuda

    Sorry about that. Attatched a new patch file including test cases.

    February 14th, 2009 @ 02:10 PM

  3. Akira Matsuda
    Akira Matsuda

    I rethinked and changed my mind.

    This bytesize method may induce some needless surprize, because String#bytesize should not be == String#size in many other cases.

    Please reject and forget about this patch (I'm sorry it seems that I can't cancel the ticket by myself...)

    February 14th, 2009 @ 04:03 PM

  4. Michael Koziarski
    Michael Koziarski
    • State changed from new to invalid

    invalidating as per the submitters test

    February 14th, 2009 @ 09:41 PM