Just wondering why the Block class was eliminated. (I missed a
few weeks of ruby-talk and ruby-core, but I don’t think it was
discussed there – correct me if I’m wrong.)
Pardon my ignorance… I didn’t know
there ever was a Block class.
Hal
···
----- Original Message -----
From: dblack@superlink.net
To: “ruby-talk ML” ruby-talk@ruby-lang.org
Sent: Friday, July 18, 2003 12:53 PM
Subject: what happened to Block class?
Hello –
Just wondering why the Block class was eliminated. (I missed a
few weeks of ruby-talk and ruby-core, but I don’t think it was
discussed there – correct me if I’m wrong.)
----- Original Message -----
From: dblack@superlink.net
To: “ruby-talk ML” ruby-talk@ruby-lang.org
Sent: Friday, July 18, 2003 12:53 PM
Subject: what happened to Block class?
Hello –
Just wondering why the Block class was eliminated. (I missed a
few weeks of ruby-talk and ruby-core, but I don’t think it was
discussed there – correct me if I’m wrong.)
???
Pardon my ignorance… I didn’t know
there ever was a Block class.
It existed briefly in CVS. I believe it grew out of the discussions
of different argument semantics for blocks and procs (see the thread
at http://www.ruby-talk.org/70034).
Just wondering why the Block class was eliminated. (I missed a
few weeks of ruby-talk and ruby-core, but I don’t think it was
discussed there – correct me if I’m wrong.)
???
Pardon my ignorance… I didn’t know
there ever was a Block class.
It existed briefly in CVS. I believe it grew out of the discussions
of different argument semantics for blocks and procs (see the thread
at http://www.ruby-talk.org/70034).
It has been merged to Proc again. Now they are distinguished
by how to create.
$ ruby -e ‘Proc.new {|a,b|}.call’
$ ruby -e ‘proc {|a,b|}.call’
-e:1: wrong number of arguments (0 for 2) (ArgumentError)
from -e:1:in `call’
from -e:1
Just wondering why the Block class was eliminated. (I missed a
few weeks of ruby-talk and ruby-core, but I don’t think it was
discussed there – correct me if I’m wrong.)
???
Pardon my ignorance… I didn’t know
there ever was a Block class.
It existed briefly in CVS. I believe it grew out of the discussions
of different argument semantics for blocks and procs (see the thread
at http://www.ruby-talk.org/70034).
It has been merged to Proc again. Now they are distinguished
by how to create.
$ ruby -e ‘Proc.new {|a,b|}.call’
$ ruby -e ‘proc {|a,b|}.call’
-e:1: wrong number of arguments (0 for 2) (ArgumentError)
from -e:1:in `call’
from -e:1
Can you elaborate on the reason for doing it that way, instead of a
different class? The Block class seemed much cleaner to me.
It has been merged to Proc again. Now they are distinguished
by how to create.
$ ruby -e ‘Proc.new {|a,b|}.call’
$ ruby -e ‘proc {|a,b|}.call’
-e:1: wrong number of arguments (0 for 2) (ArgumentError)
from -e:1:in `call’
from -e:1
Can you elaborate on the reason for doing it that way, instead of a
different class? The Block class seemed much cleaner to me.
According to Matz diary (Matzにっき(2003-06-16)),
apparently, because they are too similar.
Can you elaborate on the reason for doing it that way, instead of a
different class? The Block class seemed much cleaner to me.
According to Matz diary (Matzにっき(2003-06-16)),
apparently, because they are too similar.
If you want better explanation, ask Dave Thomas. I explained this
issue to him face to face at the OSCON last week about for half hour.
I believe he understood both the behavior and the reason.