https://redmine.ruby-lang.org/https://redmine.ruby-lang.org/favicon.ico?17113305112018-01-05T14:32:17ZRuby Issue Tracking SystemRuby master - Feature #14316: Update Status Code classeshttps://redmine.ruby-lang.org/issues/14316?journal_id=692222018-01-05T14:32:17Znormalperson (Eric Wong)normalperson@yhbt.net
<ul></ul><p><a href="mailto:zn@mbf.nifty.com" class="email">zn@mbf.nifty.com</a> wrote:</p>
<blockquote>
<p>0001-Specify-frozen_string_literal-true.patch (697 Bytes)</p>
</blockquote>
<p>0001 seems pointless, only strings in that file are literal hash<br>
keys and they are all frozen since 2.1<br>
(I also wrote<br>
<a href="http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/438693" class="external">http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/438693</a><br>
the other day)</p>
<blockquote>
<p>0002-Add-103-Early-Hints.patch (1.11 KB)</p>
</blockquote>
<p>Seems fine.</p>
<blockquote>
<p>0003-Update-Status-Code.patch (3.93 KB)</p>
</blockquote>
<p>Thank you for keeping old constants for compatibility. I guess<br>
new constants are nice for people reading current documentation;<br>
but they add cognitive overhead for users experienced with the<br>
old names :<</p>
<p>I wonder if we should slowly move towards using classes based on<br>
the numbers instead, and leave the unstable English phrasing out<br>
of our API...</p> Ruby master - Feature #14316: Update Status Code classeshttps://redmine.ruby-lang.org/issues/14316?journal_id=692412018-01-05T20:57:49Znaruse (Yui NARUSE)naruse@airemix.jp
<ul></ul><p>Looks fine.<br>
Could you commit them?</p>
<blockquote>
<blockquote>
<p>0001-Specify-frozen_string_literal-true.patch (697 Bytes)</p>
</blockquote>
<p>0001 seems pointless, only strings in that file are literal hash<br>
keys and they are all frozen since 2.1</p>
</blockquote>
<p>This patch actually does nothing.<br>
But it prevents that a future change accidentally adds mutable strings.<br>
This change also fine to me.</p> Ruby master - Feature #14316: Update Status Code classeshttps://redmine.ruby-lang.org/issues/14316?journal_id=693872018-01-06T04:58:37Zznz (Kazuhiro NISHIYAMA)
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Closed</i></li></ul><p>I commited at r61633, r61634, r61635.</p> Ruby master - Feature #14316: Update Status Code classeshttps://redmine.ruby-lang.org/issues/14316?journal_id=695442018-01-11T12:58:22Zznz (Kazuhiro NISHIYAMA)
<ul></ul><blockquote>
<p>I wonder if we should slowly move towards using classes based on<br>
the numbers instead, and leave the unstable English phrasing out<br>
of our API...</p>
</blockquote>
<p>I think <code>Net::HTTP::STATUS_CODES</code> is added for such purpose.<br>
<a href="https://bugs.ruby-lang.org/issues/12935" class="external">https://bugs.ruby-lang.org/issues/12935</a></p>