[#927] UnboundMethod#to_proc — Dave Thomas <dave@...>
I'm wondering what I can do with a Proc generated by
17 messages
2003/04/06
[#929] Re: UnboundMethod#to_proc
— "Chris Pine" <nemo@...>
2003/04/06
----- Original Message -----
[#934] Re: UnboundMethod#to_proc
— Mathieu Bouchard <matju@...>
2003/04/06
[#940] Re: UnboundMethod#to_proc
— chr_news@...
2003/04/07
>
[#941] Re: UnboundMethod#to_proc
— Dave Thomas <dave@...>
2003/04/07
>> If they have diverging interfaces such that the contracts conflict
[#936] docs on implementation of ruby and/or ruby-gc ? — Ruben Vandeginste <Ruben.Vandeginste@...>
4 messages
2003/04/07
[#964] Range in logical context — Dave Thomas <dave@...>
If I run
7 messages
2003/04/16
[#965] Re: Range in logical context
— Mauricio Fern疣dez <batsman.geo@...>
2003/04/16
On Thu, Apr 17, 2003 at 06:10:40AM +0900, Dave Thomas wrote:
[#973] problem with rb_rescue2() ? — Mathieu Bouchard <matju@...>
5 messages
2003/04/19
Possible inconsistency in IO
From:
matz@... (Yukihiro Matsumoto)
Date:
2003-04-01 23:54:16 UTC
List:
ruby-core #924
Hi,
Somehow, Dave Thomas used his unregistered address, which rejected by
the list server.
In message "NOT MEMBER article from dave@pragprog.com (ruby-core ML)"
on 03/04/02, ruby-core-admin@ruby-lang.org <ruby-core-admin@ruby-lang.org> writes:
|NOT MEMBER article from dave@pragprog.com
|
|
|Original mail as follows:
|
| Date: Tue, 1 Apr 2003 15:25:43 -0600
| Subject: Possible inconsistency in IO
| From: Dave Thomas <dave@pragprog.com>
| To: ruby-core@ruby-lang.org
|
| This is pretty trivial, but IO.new warns if it is passed a block, but
| IO.for_fd doesn't (but it does ignore the block).
|
| Two questions:
|
| 1. Is this correct?
Yes. It is too easy to confuse IO.open and IO.new, so that I decided
to warn it. In fact, I myself confused to make IO.new to take a block
for a while.
| 2. Is there any other external difference between the two methods?
No, they are identical except for this warning. But your question
made me realize that I need to reject File.for_fd(path), but
File.new(path). I will fix this soon.
Summary:
(a) IO.new warns because *I* made mistake. This warning should be
removed in the future.
(b) IO.for_fd should only take a file descriptor number, even for IO's
subclasses, e.g. File.for_fd().
matz.