For the record, I think that the new choice of default is poor. People have a normal everyday expectation for how numbers are rounded. I claim that the expectation is that >= .5 rounds up, <.5 rounds down. I cite as evidence: ...meta (mathew murphy)
Jonathan Eyler-Werve wrote: > If I were moderating this exchange, I think a clear set of guidelines for participation with clear enforcement policies would be useful right now. Exactly. All discussions of Codes of Conduct eventually ...meta (mathew murphy)
This just cropped up on Reddit. A user was confused by URI.escape's behavior, why it was obsolete, and what should be used instead. So, here's a trivial doc patch: ``` diff --git a/lib/uri/common.rb b/lib/uri/common.rb index 4c7d112...meta (mathew murphy)
Now that I read [the documentation on encodings](http://ruby-doc.org/core-2.0/Encoding.html) more carefully, I think the real problem is more fundamental: `__ENCODING__` doesn't determine the encoding of *all* created strings; it only af...meta (mathew murphy)
The Ruby documentation says: M | **String** | quoted printable, MIME encoding (see RFC2045) And [RFC 2045](http://tools.ietf.org/html/rfc2045) section 6.7 says: > The Quoted-Printable encoding is intended to represent data th...meta (mathew murphy)
In case there's confusion because of the strange splits in my examples: ["ünicode"].pack('M*').unpack('M*').first.encoding.name => "ASCII-8BIT" meta (mathew murphy)
New strings are generated in the default encoding: irb> __ENCODING__.name => "UTF-8" irb> "ünicode".encoding.name => "UTF-8" ...but not if they're generated by unpack: irb> "ünicode".split.pack('M*').unpac...meta (mathew murphy)
This still seems to be a problem in Ruby 2.1.1p76. Data ends up as ASCII-8BIT even if the server specifies that it's UTF-8 or ISO-8859-1, and I end up with errors when writing it out somewhere else as a result.meta (mathew murphy)