https://bugs.ruby-lang.org/https://bugs.ruby-lang.org/favicon.ico?17097754782012-10-06T22:49:22ZRuby Issue Tracking SystemRuby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=301222012-10-06T22:49:22ZEregon (Benoit Daloze)
<ul></ul><p>Good catch!</p>
<p>There are a few special cases:</p>
<ul>
<li>dotfiles (e.g.: ".hidden") have "" for extname and ".hidden" for basename.</li>
<li>files ending with a dot report "" as extname (done by rb_file_s_extname())</li>
<li>looking at ruby_enc_find_extname(), the part after ':' is not kept for NTFS paths.</li>
</ul> Ruby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=322782012-11-03T12:23:39Zzzak (zzak _)
<ul></ul><p>Eregon, what do you suggest?</p>
<p>I sorta feel like covering every special case would be bad, but maybe add a few more examples?</p> Ruby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=324362012-11-06T00:20:12Zmame (Yusuke Endoh)mame@ruby-lang.org
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Assigned</i></li><li><strong>Assignee</strong> set to <i>drbrain (Eric Hodel)</i></li></ul><p>Drbrain, could you handle this?</p>
<p>--<br>
Yusuke Endoh <a href="mailto:mame@tsg.ne.jp" class="email">mame@tsg.ne.jp</a></p> Ruby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=328822012-11-14T10:20:47Zdrbrain (Eric Hodel)drbrain@segment7.net
<ul></ul><p>I think adding documentation for dotfiles and files ending with a dot would be sufficient.</p>
<p>I don't think covering filesystem-specific behavior is necessarily useful.</p> Ruby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=328832012-11-14T10:22:55Zzzak (zzak _)
<ul><li><strong>Assignee</strong> changed from <i>drbrain (Eric Hodel)</i> to <i>zzak (zzak _)</i></li><li><strong>Target version</strong> set to <i>2.0.0</i></li></ul> Ruby master - Bug #7112: File.extname documentation fixhttps://bugs.ruby-lang.org/issues/7112?journal_id=331742012-11-20T15:37:56Zzzak (zzak _)
<ul><li><strong>Status</strong> changed from <i>Assigned</i> to <i>Closed</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul><p>This issue was solved with changeset r37749.<br>
Noah, thank you for reporting this issue.<br>
Your contribution to Ruby is greatly appreciated.<br>
May Ruby be with you.</p>
<hr>
<ul>
<li>file.c (File.extname): Documentation for extname on dotfiles and<br>
files ending with a dot. Also, added example for this.<br>
<a href="/issues/7112">[ruby-core:47852]</a> [Bug <a class="issue tracker-1 status-5 priority-4 priority-default closed" title="Bug: File.extname documentation fix (Closed)" href="https://bugs.ruby-lang.org/issues/7112">#7112</a>]</li>
</ul>