Static typing
Shane Hathaway
shane at zope.com
Fri Jul 25 21:00:00 EDT 2003
On 07/25/2003 07:36 PM, Neil Hodgson wrote:
> 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:
> http://wingide.com/psupport/wingide-1.1/node5.html#SECTION00580000000000000000
Excellent. It's nice to have an idea validated. :-)
Shane
More information about the Python-list
mailing list