[#2529] concerns about Proc,lambda,block — "David A. Black" <dblack@...>

Hi --

39 messages 2004/03/01
[#2531] Re: concerns about Proc,lambda,block — ts <decoux@...> 2004/03/01

>>>>> "D" == David A Black <dblack@wobblini.net> writes:

[#2533] Re: concerns about Proc,lambda,block — "David A. Black" <dblack@...> 2004/03/01

Hi --

[#2537] Re: concerns about Proc,lambda,block — matz@... (Yukihiro Matsumoto) 2004/03/01

Hi,

[#2542] Re: concerns about Proc,lambda,block — Mathieu Bouchard <matju@...> 2004/03/02

[#2545] Re: concerns about Proc,lambda,block — matz@... (Yukihiro Matsumoto) 2004/03/02

Hi,

[#2550] Re: concerns about Proc,lambda,block — Mauricio Fern疣dez <batsman.geo@...> 2004/03/03

On Wed, Mar 03, 2004 at 07:51:10AM +0900, Yukihiro Matsumoto wrote:

[#2703] Proposed patch to add SSL support to net/pop.rb — Daniel Hobe <daniel@...>

This patch adds support to Net::POP for doing POP over SSL. Modeled on how

19 messages 2004/03/27
[#2704] Re: Proposed patch to add SSL support to net/pop.rb — Daniel Hobe <daniel@...> 2004/03/27

This is v2 of the patch. Cleaned up a bit and added some more docs.

[#2707] Re: Proposed patch to add SSL support to net/pop.rb — Daniel Hobe <daniel@...> 2004/03/28

v3 of the patch:

[#2721] Re: Proposed patch to add SSL support to net/pop.rb — Minero Aoki <aamine@...> 2004/03/30

Hi,

Re: Duck typing chapter

From: "Warren Brown" <wkb@...>
Date: 2004-03-05 23:44:40 UTC
List: ruby-core #2596
Dave,

> I've posted a rough first pass at a chapter about duck typing (and
> other typing issues in Ruby). It covers
> 
> - what a type is
> - duck typing
> - Ruby's built-in protocols (to_str, to_proc, etc)
> - coercion and double dispatch
> 
>    http://www.pragmaticprogrammer.com/extracts/ducktyping.pdf
> 
> It isn't typeset, and I haven't really read it through for typos. I'd
> be interested to see what folks think. Again, all feedback gratefully
> received.

    One thing that stuck out to me is that after explaining that in Ruby
the class is not the type, the class Roman tests the class of its
parameters (i.e. "if Integer === other").  In this case you could (and
probably will) argue that the class *is* the type, but this should
probably be specifically stated to the reader to avoid confusion.

    I'm sure you'll find all of the easy typos, but there is a subtle
one in the Roman#initialize method (no not the "muts" one).  The error
message should say "<= #{MAX_ROMAN}", not "< #{MAX_ROMAN}".

    The only other thing that struck me as odd was the assumption in
Roman#coerce that any parameter that is not a Fixnum should be converted
to a Float.  This seems a bit simplistic, especially with Bignum as a
built-in class, and would seem to preclude using some other Integer-like
class (Chinese number?).  Perhaps a check for a to_int method would be
more appropriate?

    Anyway, the rest looks good.  I look forward to the next edition!

    - Warren Brown



In This Thread