Static typing

Neil Hodgson nhodgson at
Sat Jul 26 01:36:20 CEST 2003

Shane Hathaway:

> Well, here's a pattern I've been trying out for this purpose: use assert
> statements at the top of the function.
> def foo(bar, baz):
>      assert isinstance(bar, int)
>      assert isinstance(baz, str)

   The Wing IDE will read assertions of the above form and provide more
assistance than with identifiers it knows nothing about:


More information about the Python-list mailing list