News for hackers. Stuff that matters.
Re:Never create Ruby strings longer than 23 characters by al2o3cr on Wednesday December 11, 2013 @10:59AM (#6888248)
It's using the storage in an RString struct that isn't otherwise occupied by the RBasic info:

https://github.com/ruby/ruby/blob/8f77cfb308061ff49de0a47e82...

Note the `as` union. The `heap` version has three VALUE-sized entries, so RSTRING_EMBED_LEN_MAX is calculated accordingly, with the -1 to account for the null terminator.

There are no comments on this comment yet.