From: matz@... (Yukihiro Matsumoto) Date: 2003-11-20T06:38:21+09:00 Subject: Re: "stereotyping" (was: Re: Strong Typing (Re: Managing metadata about attribute types) Hi, In message "Re: "stereotyping" (was: Re: Strong Typing (Re: Managing metadata about attribute types)" on 03/11/20, "Sean O'Dell" writes: |> library is requiring Socket interface, but without that kind of |> interface check, no flexibility is lost, it's little bit hard to find |> out the semantics. | |When a method is written to use the methods of another object, and that code |is distributed as a library, the function of that method is fixed. You must |pass it an object that has the methods it requires, and those methods must |take the exact parameters it expects. | |The flexibility to change the method of the object is lost. You cannot change |the parameters to the "send" method of a Socket object and pass it to a |library that uses it. You will get an error deep inside the library. I don't understand "the flexibility to change the method of the object". What is that? I think it has never existed before. We cannot lose something that has never existed. |> |Reconsider, Matz. |> |> Reconsider what? I didn't tell you any decision yet. I'm still |> the level of seeking what you mean. | |You said the following: | |> I admit type checking can gain you something, at the cost of |> flexibility, which I don't want to pay in Ruby. | |You don't want to pay the price of type checking in Ruby. My version of it is |really "interface checking," but either way what you said sounds like you've |decided you don't want to pay the price for any of this. You've misunderstood me. I don't want to pay "the cost of losing flexibility", that means I don't want to make any change hindersc "my" flexibility, which can be harmed by "type checking based on inheritance". Since your "interface checking" do not affect "flexibility" in bad manner, I said nothing against it. But still, there's no known effective way to define and check "interface" in a language so dynamic as Ruby. Long way to go. matz.