From: Dave Thomas Date: 2001-01-19T10:33:23+09:00 Subject: [ruby-talk:9530] Re: reading an entire file as a string matz@zetabits.com (Yukihiro Matsumoto) writes: > In fact, > > buff = File.open(path){|f|f.read} > > gives whole contents of a file. But I admit it's too hard to > understand at a first sight. if (rb_block_given_p()) { return rb_ensure(rb_yield, file, rb_io_close, file); } Sneaky. That's a documentation bug in the book, then. Thanks, matz. Dave