--- Comment #37 from Walter Bright <> 2012-05-04 
14:13:50 PDT ---
(In reply to comment #36)
> (In reply to comment #35)
> <snip>
> > Again, this is NOT true. The type of the argument is not statically 
> > A, it is a polymorphic type A.
> Why do you consider the contracts of a method to be NOT part of the API? 

This is not what I am considering. I am saying that A is a polymorphic type,
not a static type. The contracts that apply depend on the runtime polymorphic
type, not the static type.

> Because Bertrand considers it so, or for some other reason?

I am not using argument by authority. Meyer explains it quite well, step by
step, in his book I recommended to you. The behavior is an inevitable
consequence of the fundamental principles of OOP. That is why it is not a
matter of opinion.

> > If an instance of A is passed, then the call to foo(-1) will fail. 
> > Please try it and see for yourself.
> I never doubted that.

Then I am lost as to what you think is broken in the design.

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to