> Static != non-duck.
> One could imagine static duck typing (is it the same as structural
> typing?) with type inference. I wonder if some existing languages have
> static duck typing (boo? haskell?).
C++ (using templates).
___
Python-3000 mailing lis
> Non-duck typing is a seriously bad idea, forced
> on some other languages by static typing.
Static != non-duck.
One could imagine static duck typing (is it the same as structural
typing?) with type inference. I wonder if some existing languages have
static duck typing (boo? haskell?).
__
Bill Janssen writes:
> I don't want to ever again use a library that claims to export a
> "dict" object, only to find (later) that the implementor hasn't
> implemented some of the methods of the real "dict" type because he
> thought they wouldn't be called.
And there is the crux of the matter. I *
Bill Janssen wrote:
> I think that there is little of advantage in the Java type system to
> be adopted into Python. One possible addition is the often-discussed
> optional type declarations and associated ability to define an
> interface for a module or class.
The problem with something like th
> A language with the same type system
> as Java, but enforced at run time instead of compile
> time, would be just as annoying to use.
Python already has a different, and in many respects better, type
system than Java has. I'm simply suggesting that the common practice
of ignoring -- or worse, s
Alex Martelli <[EMAIL PROTECTED]> writes:
> Java's typechecking IS enforced at runtime just about each and every
> time you cast something (I'm told the need for casting has diminished
> with Java 1.5's generics, but I have no experience of 1.5; earlier,
> casts abounded each time you used c
On May 6, 2006, at 6:37 PM, Greg Ewing wrote:
...
> The disadvantages associated with very strong type systems
> arise because of their strength, not whether they are
> static or dynamic. A language with the same type system
> as Java, but enforced at run time instead of compile
> time, would
Bill Janssen wrote:
> Thanks, Antoine, but I don't want strong static typing at all. I
> wouldn't mind optional partial static typing, but what I want is
> strong *dynamic* typing
How strong do you want it, exactly?
The disadvantages associated with very strong type systems
arise because of the
> If you want a Python-lookalike with strong static typing (and optional
> duck typing with the "duck" keyword!), then try Boo:
> http://boo.codehaus.org/Home
Thanks, Antoine, but I don't want strong static typing at all. I
wouldn't mind optional partial static typing, but what I want is
strong *
Le samedi 06 mai 2006 à 08:05 -0400, Blake Winton a écrit :
> Bill Janssen wrote:
> > GvR writes:
> >>On 5/5/06, Bill Janssen <[EMAIL PROTECTED]> wrote:
> >Is there anywhere else in Python where the type of an object isn't
> >checkable with isinstance()?
> Yes, it's called duck typing.
10 matches
Mail list logo