From: "niku (niku _)" Date: 2012-09-26T17:51:17+09:00 Subject: [ruby-dev:46163] [ruby-trunk - Feature #6528] Add Pathname#write and Pathname#binwrite Issue #6528 has been updated by niku (niku _). > IO.read と対応する Pathname#read があるので > IO.write と対応する Pathname#write が欲しいです. > > IO.write がない現在は pathname.open('w') { |f| f << str } などと書かなくてはならず,冗長ですが > IO.write があれば pathname.write(str) と書けて,簡潔です. のところ、 > IO.read と対応する Pathname#read があるので > IO.write と対応する Pathname#write が欲しいです. > > pathname.write がない現在は pathname.open('w') { |f| f << str } などと書かなくてはならず,冗長ですが > pathname.write があれば pathname.write(str) と書けて,簡潔です. の誤りでしたので訂正します。 ---------------------------------------- Feature #6528: Add Pathname#write and Pathname#binwrite https://bugs.ruby-lang.org/issues/6528#change-29746 Author: niku (niku _) Status: Assigned Priority: Normal Assignee: akr (Akira Tanaka) Category: ext Target version: IO.read と対応する Pathname#read があるので IO.write と対応する Pathname#write が欲しいです. IO.write がない現在は pathname.open('w') { |f| f << str } などと書かなくてはならず,冗長ですが IO.write があれば pathname.write(str) と書けて,簡潔です. Pathname#write と Pathname#binwrite を実装したパッチを添付します. -- http://bugs.ruby-lang.org/